Sounds like the architecture of your device doesn't fit very well
with USB. Asynchronous traffic is not guaranteed bandwidth (you
should use isochronous for that). If the "out of sync" problem
happens only infrequently, could you reset your device to recover?
Do you have any control over the firmware in the device? Since you
said it's a small amount of data, you may wish to change your bulk
endpoints into periodic ones (ie, Interrupt).
Can you submit more than 250ms worth of requests, so the host is
always getting the data,and the buffering occurs before your
application/driver gets it?
Does your device send short packets when there is no more data
available? This is a good technique that allows you to submit
larger requests, and still get low latency when you've "caught up"
with the device.
Hope this helps.
David Ferguson
USB Software Team
Apple Computer
At 11:00 AM -0700 9/1/05, Robert Bell wrote:
Hi all,
I wrote an email a while ago, but unfortunately I might have
missed any replies as a result of a mailbox issue (so thanks to
anyone who has replied, and sorry to have to post it again).
The issue is as follows. We are doing asynchronous (not
isochronous) communication to a device that has only 0.25 seconds
of buffer. Unfortunately, if we do not keep up with the device,
we cannot re-synchronize. Thus we must drain its buffer in time
(it is a pre-usb 2 device, so data traffic is not massive). The
issue we are seeing is that every so often, our time-stamps
indicate that we have delayed in our acquisition for more than
0.25 seconds. We can also force this to happen more often if we
load down the machine (as one might expect). We currently load the
requests on the bus to about 4-8 concurrent requests (to try to
improve the situation).
The questions I have are:
1) Does a >0.25 delay sound reasonable to you guys? Ie, is it
possible that our usb request could be off the cpu for that much
time?
2) After reading a bunch of past posts (by Fernando Urbina)
there seems to be an indication that if this indeed can occur,
there is little that we can do as it is an issue with how the
primary interrupt handler passes off events to the secondary
handler. This email was written back in 2002 though, and I was
wondering if there has been a work-around implemented in the
meantime.
I would be happy to send current code samples if that would
make life easier. It just seems odd that we would really be off
the scheduler for that long.
Thanks for any help!!
Robert.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Usb mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/usb/email@hidden
This email sent to email@hidden