Skip navigation
  • Handling of vendor-specific Usage Pages
  • Ready to use code examples for keyboard, mouse and vendor-specific HID
  • No host driver required for Windows / Linux / 
    macOS
  • Small footprint

emUSB-Device HID

The Human Interface Device class (HID) is an abstract USB class protocol defined by the USB Implementers Forum. This protocol was defined for the handling of devices which are used by humans to control the operation of computer systems. An installation of a custom-host USB driver is not necessary, because the USB Human Interface Device class is standardized and every major OS already provides host drivers for it.

Typical Applications

  • Keyboard
  • Mouse and similar pointing devices
  • Joystick
  • Game pad
  • Front-panel controls - for example, switches and buttons.

HID Categories

Devices which are in the HID class basically fall into one of two categories:
"True HIDs" and vendor specific HIDs, explained in the following paragraphs. One or more examples for both categories are provided.

 

True HIDs

HID devices communicating with the host operating system. Devices which are used by a human being to input / output data, but do not directly exchange data with an application program running on the host.

 

Vendor Specific HIDs

These are HID devices communicating with an application program. The host OS loads the same driver it loads for any "true HID" and will automatically enumerate the device, but it can not communicate with the device. When analyzing the report descriptor, the host finds out that it can not exchange information with the device; the device uses a protocol which is meaningless to the HID driver of the host. The Host will therefore not exchange information with the device. A host recognizes a vendor specific HID by its vendor defined usage page in the report descriptor: The numerical value of the usage page is between 0xFF00 and 0xFFFF. An application has the chance to communicate with the particular device using API functions offered by the host. This allows an application program to communicate with the device without having to load a driver. HID does not take advantage of the full USB bus bandwidth; bulk communication can be much faster, but requires a driver. Therefore it can be a good choice to select HID as device class, especially if easy-of use is important and achieving the best communication speed is not a requirement.

 

 

Resource Usage by this Component

ROM usage RAM usage
App. 1.6 KByte  App. 100 Byte