HID Input Support?

Is there support for HID USB controllers in Juce somewhere?

I donā€™t even know what HID stands forā€¦

Hardware vendors are finally moving away from MIDI and going to this new protocol, which supports higher resolution (i.e. faster) message passing. Unfortunately, it is an unstructured protocol so every company ends up creating their own proprietary layer on top of HID (which seems to be more of a transport level protocol).

The Native Instruments Kontrol S4 uses HID with Traktor, and the messages it passes are part of a proprietary NI protocol called ā€œNHL.ā€ - Native Hardware Library:

Found a cross-platform library that does HID, its got a good explanation on the page:

http://www.signal11.us/oss/hidapi/

FWIW, I think that the move to HID was partially driven by a desire not to write and support USB drivers. All the desktop OSā€™s understand HID, because everyone has keyboards and mice, so identifying yourself as a HID class device gives you a standard driver path to user space without writing and signing a driver.

I havenā€™t looked at the library Vinnie found, but I also have classes for HID that Iā€™d be willing to share. A lot of adaptive technology stuff for the disabled works via HID, which is why I wrote it. I also have classes and drivers for generic USB device access which I just ā€˜jucedā€™ (not just switched from standard library to juce, but turned all the resource classes into RAII style reference counted objects, etc.) Generic low level access is useful if you want to utilize a device that doesnā€™t support a standard class like HID.

Iā€™d planned on turning this into juce modules at some point anyway, though the generic USB access is a lot more juce friendly than my HID abstraction stuff right now.

1 Like

Hi there @jfitzpat, I know this is an old thread, but I would be very interested in any resources you have on HID support within JUCE.

1 Like