Re: question on initiating gadget out/in transfer
David Brownell <[email protected]>
| Newsgroups | gmane.linux.usb.devel |
|---|---|
| Message-ID | <20070907062421.3633B20DDC8@adsl-69-226-248-13.dsl.pltn13.pacbell.net> |
> i am writing a driver for a controller to support > the gadget api, so far i can enumerate the > device Good, that means you're near the first milestone. Make sure it passes all the "usbtest" control test cases, including running test #10 for a few hours. . but i am not sure on how to invoke > ins and outs on the gadget side. In response to a SET_CONFIGURATION request, or after that's done sometimes in response to a SET_INTERFACE (altsetting) request. > with control > transfers it is straightforward, i get a control > packet and then call the setup() function to > forward it to gadget. Yes. > my theory was that with > regular transfers gadget would queue an > in and an out request at all times and my driver > would call the complete() function once it would > fill in the buffer, If by "fill in the buffer" you copying data from the controller FIFO for OUT data, or copying it into the corresponding FIFO for IN data, yes ... Note that you have a simple operational test for this, called "Gadget Zero". That code works right, so if your it doesn't work right with your driver then the problem is in your code. > but i do not see that happening; > so either i am doing something wrong or the > gadget api uses a different mechanism. It's hard to know exactly what you mean to say, but as I pointed out above there's already a simple illustration in "gadget zero". If that driver doesn't work, you're doing something wrong. - Dave ------------------------------------------------------------------------- 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/ _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel