-
Notifications
You must be signed in to change notification settings - Fork 441
macOS support for multiple usage/usage-pages #125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Update of @fengji2006 PR#65, second try
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good overall
A small suggestion from my side: |
Oh apologies. I debated what was the correct approach. Noted for next time. And thanks for being patient with me. |
We're a team here :) |
This reverts commit ca1a2d6. Currently breaks razer_test, see libusb#155
NOTE: This commit does not handle composite HID descriptors I am interested in adding support for composite descriptors though I still need to find a device with a composite descriptor to test it correctly. The implementation idea is similar, as in #125 for macOS.
NOTE: This commit does not handle composite HID descriptors I am interested in adding support for composite descriptors though I still need to find a device with a composite descriptor to test it correctly. The implementation idea is similar, as in #125 for macOS.
Update of @fengji2006 PR#65, second try.
I think this includes all the requested changes, on top of the work done by @fengj2006 on #65. Unlike the previous attempt, I think this doesn't regress the other recent changes made.
You can now see all the different usages as different "devices" in
hid_enumerate()
. When runninghidtest
you see them too. On a Macbook Pro with internal keyboard/trackpad, there are many:Additionally, I've verified that an Arduino "RawHID" device with two usages shows up as two devices to hidapi. The device is a $9 Trinket M0 running TinyUSB pretending to be a Teensy in RawHID mode. See the "tinyusb_teensyrawhid_multiusage" sketch if you'd like to create a similar physical device to test against.