Closed larsks closed 4 years ago
This is due to a range limit in the keyboard HID descriptor, limiting the top value of the keycode:
https://github.com/adafruit/circuitpython/blob/44cf7988c04e7390a713b351e72d75b1708de20c/tools/hid_report_descriptors.py#L73. This descriptor was taken from a "standard" USB PC keyboard, but we should really make the range limit 0xdd
. See https://www.usb.org/sites/default/files/documents/hut1_12v2.pdf#page=59 for the values we should include up to.
I'll transfer this issue to https://github.com/adafruit/circuitpython. It is a CircuitPython issue, not a library issue. Thanks for discovering this!
I'm trying to send keycodes from the Gemma M0 to a Linux host. I wanted to configure three buttons to send F13, F14, and F15. While this works just fine:
This fails to send anything at all:
I notice that when using
evtest
to try to debug the problem, I see this report when connecting to the keyboard endpoint:It appears that the HID driver is explicitly declaring that it only supports the keycode listed in the above output. Is there any way to get CP to send arbitrary HID keycodes?