|
From: Xiaofan C. <xia...@gm...> - 2010-04-22 00:08:08
|
On Thu, Apr 22, 2010 at 7:56 AM, Jason Kotzin <jas...@gm...> wrote: > Sorry, the application doesn't work, but I get a more verbose output. > > The control message still gives back 0 when it should give back 0xFF. > Now you are using feature reports judging from the debug log, right? Please post the HID report descriptor. In that case, you should use the example in xusb. r = libusb_control_transfer(handle, LIBUSB_ENDPOINT_IN|LIBUSB_REQUEST_TYPE_CLASS|LIBUSB_RECIPIENT_INTERFACE, HID_GET_REPORT, (HID_REPORT_TYPE_FEATURE<<8)|0, 0, report_buffer, (uint16_t)size, 5000); If you are using report ID 1 and 2, change the above (HID_REPORT_TYPE_FEATURE<<8)|0 to (HID_REPORT_TYPE_FEATURE<<8)|1 and (HID_REPORT_TYPE_FEATURE<<8)|2. Or here: http://picusb.googlecode.com/files/libusb1_lvrhid8.c If you are not using feature report, ignore the above. But you can use feature report and give it a try. -- Xiaofan http://mcuee.blogspot.com |