[libhid-discuss] help deciphering HID descriptor

Hans-Christoph Steiner hans at eds.org
Wed Nov 28 21:51:15 UTC 2007


On Nov 28, 2007, at 3:19 PM, Peter Stuge wrote:

> On Wed, Nov 28, 2007 at 02:25:01PM -0500, Hans-Christoph Steiner  
> wrote:
>>      const int path[] = {0x000c0001, 0x000c0001};
>>      long path_element;
>>      unsigned int const depth = 2;
>>      unsigned char const SEND_PACKET_LEN = 2;
>>      char const PACKET[] = { 0x50 };
>>
>>      if ( !hid_is_opened(x->x_hidinterface) )
>>      {
>>          error("[usbhid] device not open, can't set data");
>>          return;
>>      }
>>      x->x_hid_return = hid_set_output_report(x->x_hidinterface,
>>                                              path,
>>                                              depth,
>>                                              PACKET,
>>                                              SEND_PACKET_LEN);
>
> Dunno about the descriptor, but you seem to be trying to send two
> bytes when the buffer only has one.

I tried changing that a bunch, I am shooting in the dark here a bit.   
I've worked with Apple HID Utilities and Linux input.h, but this is  
lower level than I am accustomed to.

I suppose what would be really helpful is example code that generates  
the "path" using info from HIDParse().  My life would be easier if I  
could find a GNU/Linux box that had a 'lsusb -vvv' that gave me  
something other than:

Report Description:
    ** UNAVAILABLE **

.hc

------------------------------------------------------------------------ 
----

Using ReBirth is like trying to play an 808 with a long stick.    - 
David Zicarelli





More information about the libhid-discuss mailing list