Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Creating a virtual HID device

Tags:

virtual

hid

wdk

I'd like to create a virtual HID device (emulate it with a driver).

It must be visible to clients that implement standard HID detection:

  • Call HidD_GetHidGuid() – Get the HID device class GUID
  • Call SetupDiGetClassDevs() – Get a handle to a set of devices which implement the HID interface
  • Call SetupDiEnumDeviceInterfaces() – For each device in the returned set of devices, obtain the interface information for all exposed HID interfaces.
  • Call SetupDiGetDeviceInterfaceDetail() – For each interface obtained in the previous call, get the detailed information block for that interface. This detailed information includes the string that can be passed to CreateFile() to open a handle to the device
  • Call SetupDiDestroyDeviceInfoList() – Free up the device information set that was obtained in the call to SetupDiGetClassDevs().

The device should also support reading, so CreateFile / ReadFile would return data supplied by me from the driver.

I don't really know where to begin, as I don't have a lot of exp. in kernel dev. :(

like image 429
jsmith Avatar asked Jun 28 '11 10:06

jsmith


People also ask

What is a virtual UPDD HID device?

The Virtual HID device binding information is Windows system information held in the registry (digimon mapping) and is normally set up by Windows but UPDD can also setup this information using the monitor mapping function built into the UPDD software.

What is HID programming?

An HID takes input from or provides output to humans. Examples of devices include keyboards, pointing devices (mice, touchscreens, etc.), and gamepads. The HID protocol makes it possible to access these devices on desktop computers using operating system drivers.

What is HID API?

HIDAPI is a multi-platform library which allows an application to interface with USB and Bluetooth HID-Class devices on Windows, Linux, FreeBSD, and macOS. HIDAPI can be either built as a shared library ( .

Do HID devices need drivers?

If you've recently upgraded to Windows 10, reinstalled, or updated it, you may have found that you have to install (or update) your HID Keyboard drivers. In most cases, you don't actually have to do anything, or manually download and install the keyboard drivers.


1 Answers

Some people have had luck with the vmulti project as a base http://code.google.com/p/vmulti/

like image 190
djp Avatar answered Oct 29 '22 00:10

djp