anyone working on setting output items with usbhidctl(1) ?

Rene Ladan r.c.ladan at gmail.com
Tue Oct 3 02:36:00 PDT 2006


Jindra Fucik schreef:
>> Hi,
>>
>> is anyone working on setting output items with usbhidctl(1) ?
>>
>> I thought that something like -s "feature1=value1,feature2=value2,..."
>> would be nice to have.
> 
> Hi Rene, have you any progress? I do some tests on uhid & write and have
> no positive feedback.
> 
There is some progress.  I've sent PR usb/103418 containing a patch to
usbhidctl(1).
You can test the patch if you have a hid with a known output descriptor:

# usbhidctl -f /dev/uhid0 -w name=value

should do the trick.

When I test the patch with my Xbox 360 controller which contains a
reverse-engineered output descriptor it crashes when calling
hid_set_data() from libusbhid.  I guess I'm not initializing the
variable *buf correctly (it contains 0x800).

Alternatively you can import usbhidctl(1) from OpenBSD/NetBSD (some
trivial patches are needed, like s/hid_start()/hid_init() ) which has
hopefully a working -w option.

Regards,
Rene
-- 
GPG fingerprint = E738 5471 D185 7013 0EE0  4FC8 3C1D 6F83 12E1 84F6
(subkeys.pgp.net)

"It won't fit on the line."
		-- me, 2001



More information about the freebsd-hackers mailing list