Is your feature request related to a problem? Please describe.
I have a keyboard HID that I want to dynamically switch report formats between Boot Protocol and Report Protocol. Unfortunately, there is no method to get the current HID protocol setting from Adafruit_USBD_HID.
Describe the solution you'd like
Add a getProtocol method to Adafruit_USBD_HID.
Describe alternatives you've considered
I'm attempting a workaround that adds a tud_set_protocol_cb hook, but this only works when there's a single boot HID, because Adafruit_USBD_HID also doesn't expose the _instance variable.
Additional context
This seems easy enough to add by calling into tud_hid_n_get_protocol. I can submit a PR for this.
Is your feature request related to a problem? Please describe.
I have a keyboard HID that I want to dynamically switch report formats between Boot Protocol and Report Protocol. Unfortunately, there is no method to get the current HID protocol setting from
Adafruit_USBD_HID
.Describe the solution you'd like
Add a
getProtocol
method toAdafruit_USBD_HID
.Describe alternatives you've considered
I'm attempting a workaround that adds a
tud_set_protocol_cb
hook, but this only works when there's a single boot HID, becauseAdafruit_USBD_HID
also doesn't expose the_instance
variable.Additional context
This seems easy enough to add by calling into
tud_hid_n_get_protocol
. I can submit a PR for this.