5 Oct 2007 00:35
usb_resetep() pixy dust
Graeme Gill <graeme2 <at> argyllcms.com>
2007-10-04 22:35:24 GMT
2007-10-04 22:35:24 GMT
Once again I've come across a situation when using libusb under Linux, where a device that works perfectly well under MSWindows and OS X, fails to work properly under Linux. The commercial device in question is based on the Cypress CY7C63001 chip, and while most communication is done via the control path, some data is read using interrupt reads from an end point. On MSWindows and OS X the device works without any problems, but when trying the same code out on Linux, the interrupt reads mysteriously fail to work, timing out. Sprinkling some usb_resetep() pixy dust in front of each interrupt read on Linux, and hey presto, it all works ! Now it wouldn't surprise me if the device it self is partially at fault here, but if so, something about the Linux driver or the Linux portion of libusb is being a whole lot less forgiving than the other major operating system platforms. Does anyone have any light to shed on this mystery ? Graeme Gill. ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/(Continue reading)
As a start with libusb I'm satisfied with an example program that
exchanges some data with an USB device. But unfortunately:
libusb-0.1.12/tests> grep write *.c
libusb-0.1.12/tests> grep read *.c
The example programs seem only to address the search for USB devices.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>
RSS Feed