On Sun, 29 May 2005, Patrick Boettcher wrote: > Hi list, > > I successfully wrote several USB drivers in linux. Up to now all of them > used bulk-transfers to send large amounts of data (digital TV). > > Now a new device uses isochronous transfers to deliver the data to the > host system. And I'm stuck... (I have to say I don't have a data sheet, > just the usblog of the windows driver to get programming parameters) > > I would highly appreciate if someone could help me with the following > questions: > > Is there method or rule how to calcuate the number of frames/urb needed? > Do I have to calculate it at all?
There is no hard-and-fast rule. However some host controller drivers are limited as to how far in the future they can schedule an ISO transfer. You should probably have not much more than 1/2 second worth of frames queued at any time. You can divide that up into URBs almost any way you like, subject to your latency requirements. > Can you please point me to a well-written driver or documentation for > isoc-stuff in Linux? All the drivers I had a look at used a fixed number. > Is that the way to go? I don't have any good examples of drivers on hand. The documentation is scattered around the kernel source. Try reading through include/linux/usb.h for starters, if you haven't already done so. > I always get the following errors: > ehci_hcd 0000:00:1d.7: devpath 2.1 ep2in 3strikes > > What does the error mean exactly? I assume that I did something wrong... > but what? The "ehci_hcd 0000:00:1d.7" part tells you which host controller driver and which controller encountered the error. The "devpath 2.1 ep2in" part tells you the error occurred when communicating with device usb-2.1, endpoint 2, while performing an IN transfer. The "3strikes" part means three errors occurred so the controller is giving up. >From that message alone it's impossible to tell exactly what the error was. Basically all it means is that the computer was expecting a response from the USB device and didn't get one. Did you select the appropriate altsetting? Devices that support ISO transfers generally don't enable them in altsetting 0 (the default). > Where do I find the appropriate value for urb->interval for my device? Look in /proc/bus/usb/devices. Or use the value in the endpoint descriptor, which your driver can track down. Alan Stern ------------------------------------------------------- This SF.Net email is sponsored by Yahoo. Introducing Yahoo! Search Developer Network - Create apps using Yahoo! Search APIs Find out how you can build Yahoo! directly into your own Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg-q22005 _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel