Apple keyboard has two interfaces one for keyboard and another for standard media keys(not includes Apple specific).
As expected first one uses usage page 0xff(kHIDPage_AppleVendorTopCase) and usage 0x03(kHIDUsage_AV_TopCase_KeyboardFn) to send Fn key. and
Interestingly Apple keyboard seems to be 5KRO!!! hahaha.
I think If you write proper driver for windows or linux you will see Fn event. Or you can emulate Apple keyboard behavior with your DIY keyboard to send Fn to OSX but it is a bit of hassle.
Is there third-party keyboard which can send Fn event without vendor driver as Apple do? I guess no keyboard like that exist in the market because OSX keyboard driver do special only for Apple keyboard. With this magic Apple can makes their own keyboard the most useful for Mac in the market, I suspect.
Code: Select all
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 */
Another keyboard's VID broadcom 0x0a5c, it may be bluetooth keyboard(with mouse?) which has broadcom bt chip. Nothing interesting.
Code: Select all
Broadcom keyboard/mouse bluetooth?
VID: 0x0a5c 2652 Broadcom
PID: 0x4502 17666
$ echo BQEJBqEBhQEFCBkBKQMVACUBdQGVA5EClQWRAQUHGeAp55UIgQJ1CJUBgQEZACmRJv8AlQaBAMA= | base64 -d | hidrd-convert -o code
0x05, 0x01, /* Usage Page (Desktop), */
0x09, 0x06, /* Usage (Keyboard), */
0xA1, 0x01, /* Collection (Application), */
0x85, 0x01, /* Report ID (1), */
0x05, 0x08, /* Usage Page (LED), */
0x19, 0x01, /* Usage Minimum (01h), */
0x29, 0x03, /* Usage Maximum (03h), */
0x15, 0x00, /* Logical Minimum (0), */
0x25, 0x01, /* Logical Maximum (1), */
0x75, 0x01, /* Report Size (1), */
0x95, 0x03, /* Report Count (3), */
0x91, 0x02, /* Output (Variable), */
0x95, 0x05, /* Report Count (5), */
0x91, 0x01, /* Output (Constant), */
0x05, 0x07, /* Usage Page (Keyboard), */
0x19, 0xE0, /* Usage Minimum (KB Leftcontrol), */
0x29, 0xE7, /* Usage Maximum (KB Right GUI), */
0x95, 0x08, /* Report Count (8), */
0x81, 0x02, /* Input (Variable), */
0x75, 0x08, /* Report Size (8), */
0x95, 0x01, /* Report Count (1), */
0x81, 0x01, /* Input (Constant), */
0x19, 0x00, /* Usage Minimum (None), */
0x29, 0x91, /* Usage Maximum (KB LANG2), */
0x26, 0xFF, 0x00, /* Logical Maximum (255), */
0x95, 0x06, /* Report Count (6), */
0x81, 0x00, /* Input, */
0xC0 /* End Collection */
$ echo BQEJAqEBhQIJAaEABQkZASkDFQAlAXUBlQOBApUBdQWBAQUBCTAJMRWBJX91CJUCgQbAwAUMCQGhAYV/BgD/dQiVAxUAJv8AGkD8KkL8sQKFfpUbGkT8Kl78sQKFfXUBlQolARpf/Cpo/IEClQaBAcA= | base64 -d | hidrd-convert -o code
0x05, 0x01, /* Usage Page (Desktop), */
0x09, 0x02, /* Usage (Mouse), */
0xA1, 0x01, /* Collection (Application), */
0x85, 0x02, /* Report ID (2), */
0x09, 0x01, /* Usage (Pointer), */
0xA1, 0x00, /* Collection (Physical), */
0x05, 0x09, /* Usage Page (Button), */
0x19, 0x01, /* Usage Minimum (01h), */
0x29, 0x03, /* Usage Maximum (03h), */
0x15, 0x00, /* Logical Minimum (0), */
0x25, 0x01, /* Logical Maximum (1), */
0x75, 0x01, /* Report Size (1), */
0x95, 0x03, /* Report Count (3), */
0x81, 0x02, /* Input (Variable), */
0x95, 0x01, /* Report Count (1), */
0x75, 0x05, /* Report Size (5), */
0x81, 0x01, /* Input (Constant), */
0x05, 0x01, /* Usage Page (Desktop), */
0x09, 0x30, /* Usage (X), */
0x09, 0x31, /* Usage (Y), */
0x15, 0x81, /* Logical Minimum (-127), */
0x25, 0x7F, /* Logical Maximum (127), */
0x75, 0x08, /* Report Size (8), */
0x95, 0x02, /* Report Count (2), */
0x81, 0x06, /* Input (Variable, Relative), */
0xC0, /* End Collection, */
0xC0, /* End Collection, */
0x05, 0x0C, /* Usage Page (Consumer), */
0x09, 0x01, /* Usage (Consumer Control), */
0xA1, 0x01, /* Collection (Application), */
0x85, 0x7F, /* Report ID (127), */
0x06, 0x00, 0xFF, /* Usage Page (FF00h), */ Vendor defined
0x75, 0x08, /* Report Size (8), */
0x95, 0x03, /* Report Count (3), */
0x15, 0x00, /* Logical Minimum (0), */
0x26, 0xFF, 0x00, /* Logical Maximum (255), */
0x1A, 0x40, 0xFC, /* Usage Minimum (FC40h), */
0x2A, 0x42, 0xFC, /* Usage Maximum (FC42h), */
0xB1, 0x02, /* Feature (Variable), */
0x85, 0x7E, /* Report ID (126), */
0x95, 0x1B, /* Report Count (27), */
0x1A, 0x44, 0xFC, /* Usage Minimum (FC44h), */
0x2A, 0x5E, 0xFC, /* Usage Maximum (FC5Eh), */
0xB1, 0x02, /* Feature (Variable), */
0x85, 0x7D, /* Report ID (125), */
0x75, 0x01, /* Report Size (1), */
0x95, 0x0A, /* Report Count (10), */
0x25, 0x01, /* Logical Maximum (1), */
0x1A, 0x5F, 0xFC, /* Usage Minimum (FC5Fh), */
0x2A, 0x68, 0xFC, /* Usage Maximum (FC68h), */
0x81, 0x02, /* Input (Variable), */
0x95, 0x06, /* Report Count (6), */
0x81, 0x01, /* Input (Constant), */
0xC0 /* End Collection */