I did post the following discovery to the users list yesterday, but have
since realised that that was probably the wrong place for it. Hope this
*is* the right place to ask, folks. If not, then sorry.

Briefly:
I've written a driver for a USB camera which sends 1600x1200 or 800x600
images across a USB 2.0 bulk pipe. It works fine in 1600x1200 mode, but
if switched to 800x600 mode it only gets a couple of frames before it
wedges.

I took a look at the USB traffic with a (borrowed) USB analyser. Sadly,
I've had to give it back to its owner now, and won't be able to repeat
the experiment.

The bulk pipe runs in 512 byte packet mode.

Turns out that 800x600 images don't fit in an integral number of 512
byte packets, and the last packet of every image is sent as 256 bytes
(this seems perfectly legal). However, *that's* what kills linux.
Occasionally it will handle the situation right, but very soon it will
wedge and never poll that endpoint again.

You can reset the device and get going again, but that's not a lot of
good to me!

The 1600x1200 pixel images transfer just fine: They do fit in an exact
number of 512 byte packets.

I can send 800x600 images if I tell the camera to run in "16 bits per
pixel mode" where it sends 2 bytes per pixel (it just so happens that it
can do that, and thus sends an integral number of 512 byte packets of
course).

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

This has been the case since about August last year, with the 2.6.5
kernel. I'm on Fedora Core 2 with the stock 2.6.10-1.9_FC2 kernel now.

Any news would be good.
Thank you all for your time.

Steve Hosgood.




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to