Skip to content

Commit

Permalink
chore: ignore set report for now
Browse files Browse the repository at this point in the history
  • Loading branch information
jalmeroth committed Nov 23, 2024
1 parent c85e25c commit 861e6a8
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/tusb_d.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,10 @@ uint16_t tud_hid_get_report_cb(uint8_t instance, uint8_t report_id,
void tud_hid_set_report_cb(uint8_t instance, uint8_t report_id,
hid_report_type_t report_type, uint8_t const *buffer,
uint16_t bufsize) {
(void)report_id;
(void)bufsize;
// we received a SET_REPORT request to (not) send reports:
// this happens on suspend(0)
// should get reverted on resume(1)
if (instance == ITF_NUM_HID_KB && report_id == REPORT_ID_KEYBOARD &&
report_type == HID_REPORT_TYPE_OUTPUT) {
set_tud_connected(buffer[0] == 1);
}
// mostly we get type out reports from host to update keyboard leds.
// we ignore these reports for now.
printf("d[set_report] idx: %x, type: %x, buf: %x\r\n", instance, report_type,
buffer[0]);
}

0 comments on commit 861e6a8

Please sign in to comment.