Skip to content

Instantly share code, notes, and snippets.

@tmk
Created November 12, 2021 05:10
Show Gist options
  • Save tmk/e80cf735e55c86c68536decf8931c3b3 to your computer and use it in GitHub Desktop.
Save tmk/e80cf735e55c86c68536decf8931c3b3 to your computer and use it in GitHub Desktop.
Apple Keyboard HID descriptor - 05ac:021e
https://deskthority.net/viewtopic.php?p=110621&sid=9b33a6d18da5f727dc11a615fdc207fe#p110621
Apple Keyboard
VID 0x05ac 1452
PID 0x021e 542
Interface 0
$ echo BQEJBqEBBQcZ4CnnFQAlAXUBlQiBApUBdQiBAQUIGQEpBZUFdQGRApUBdQORAQUHGQAq/wCVBXUIFQAm/wCBAAX/CQN1CJUBgQLA | base64 -d | hidrd-convert -o code
0x05, 0x01, /* Usage Page (Desktop), */
0x09, 0x06, /* Usage (Keyboard), */
0xA1, 0x01, /* Collection (Application), */
0x05, 0x07, /* Usage Page (Keyboard), */
0x19, 0xE0, /* Usage Minimum (KB Leftcontrol), */
0x29, 0xE7, /* Usage Maximum (KB Right GUI), */
0x15, 0x00, /* Logical Minimum (0), */
0x25, 0x01, /* Logical Maximum (1), */
0x75, 0x01, /* Report Size (1), */
0x95, 0x08, /* Report Count (8), */
0x81, 0x02, /* Input (Variable), */
0x95, 0x01, /* Report Count (1), */
0x75, 0x08, /* Report Size (8), */
0x81, 0x01, /* Input (Constant), */
0x05, 0x08, /* Usage Page (LED), */
0x19, 0x01, /* Usage Minimum (01h), */
0x29, 0x05, /* Usage Maximum (05h), */
0x95, 0x05, /* Report Count (5), */
0x75, 0x01, /* Report Size (1), */
0x91, 0x02, /* Output (Variable), */
0x95, 0x01, /* Report Count (1), */
0x75, 0x03, /* Report Size (3), */
0x91, 0x01, /* Output (Constant), */
0x05, 0x07, /* Usage Page (Keyboard), */
0x19, 0x00, /* Usage Minimum (None), */
0x2A, 0xFF, 0x00, /* Usage Maximum (FFh), */
0x95, 0x05, /* Report Count (5), */
0x75, 0x08, /* Report Size (8), */
0x15, 0x00, /* Logical Minimum (0), */
0x26, 0xFF, 0x00, /* Logical Maximum (255), */
0x81, 0x00, /* Input, */
0x05, 0xFF, /* Usage Page (FFh), */
0x09, 0x03, /* Usage (03h), */
0x75, 0x08, /* Report Size (8), */
0x95, 0x01, /* Report Count (1), */
0x81, 0x02, /* Input (Variable), */
0xC0 /* End Collection */
Interface 1
$ echo BQwJAaEBBQx1AZUBFQAlAQnNgQYJtYECCbaBAgm4gQYJ4oEGCeqBAgnpgQKBAcA= | base64 -d | hidrd-convert -o code
0x05, 0x0C, /* Usage Page (Consumer), */
0x09, 0x01, /* Usage (Consumer Control), */
0xA1, 0x01, /* Collection (Application), */
0x05, 0x0C, /* Usage Page (Consumer), */
0x75, 0x01, /* Report Size (1), */
0x95, 0x01, /* Report Count (1), */
0x15, 0x00, /* Logical Minimum (0), */
0x25, 0x01, /* Logical Maximum (1), */
0x09, 0xCD, /* Usage (Play Pause), */
0x81, 0x06, /* Input (Variable, Relative), */
0x09, 0xB5, /* Usage (Scan Next Track), */
0x81, 0x02, /* Input (Variable), */
0x09, 0xB6, /* Usage (Scan Previous Track), */
0x81, 0x02, /* Input (Variable), */
0x09, 0xB8, /* Usage (Eject), */
0x81, 0x06, /* Input (Variable, Relative), */
0x09, 0xE2, /* Usage (Mute), */
0x81, 0x06, /* Input (Variable, Relative), */
0x09, 0xEA, /* Usage (Volume Dec), */
0x81, 0x02, /* Input (Variable), */
0x09, 0xE9, /* Usage (Volume Inc), */
0x81, 0x02, /* Input (Variable), */
0x81, 0x01, /* Input (Constant), */
0xC0 /* End Collection */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment