Hid

From WineHQ Wiki
Revision as of 12:48, 3 February 2017 by AricStewart (Talk | contribs) (Tools to use with device testing)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Maintained by Aric Stewart

If you find incorrect information here please contact me.

HID (Human Interface Devices) in WINE

Direct HID support has been added to Wine. This page is to help users and developers be able to test and use HID devices. This is not directly about DInput or XInput support and those topics should be discussed elsewhere.

Relevant Debug Channels

  • +hid: Higher level HID messages
  • +hid_report: Very noisy messages for every input and output report to hid devices
  • +plugplay: Low level native bus device releated messages

Steps to do HID Testing

  1. On Linux, by default no hidraw devices on Linux are given any access to users. So you will need to had rw permission to the /dev/hidraw<X> device that you want to have accessible in Wine. Or if you want to be wild and crazy you can add a new udev rule to add permission to all the devices as they are added. This is not necessary on Mac.
  2. (This is not necessary on the development TIP)The winebus service is not started by default yet. so you will need to start winebus. (wine net start winebus) This makes things a little complicated. I would recommend testing with a process like this:
	wine cmd
	net start winebus
	<test application>

Or you an change the service start for winebus in the registry [System\\CurrentControlSet\\Services\\WineBus] "Start"=dword:00000002

Tools to use with device testing

  • hid_test.exe: Wine tests written around direct HID access, in the wine tree dlls/hid/tests.
  • hclient.exe: This is distributed by Microsoft in the DDK (and various free download sites if you are so inclined). This tool will enumerate devices and allow for all various levels of control and exploration.
  • hid.exe: (https://www.codeweavers.com/xfer/aric/HID/ access-key: sLcm7EZ7) A quick sample application for testing HID joysticks and gamepads with source.
  • HID descriptor parser: (http://eleccelerator.com/usbdescreqparser/) a web page to parse descriptor byte strings. Useful for debugging devices.

Devices that have been tested

Device Platform(s) Status
Logitech Rumblepad 2 Linux / OS/X Working
Xbox360 Controller OS/X Working (with 3rd party drivers installed)
Steam Controller ---- Not Working
MY-POWER / CSL (low budget ps3 controller) Linux Working

Previous Talks given by Aric Stewart at WineConfs