Re: USB interrupt endpoint limitations
- From: J.R. Heisey <JRHeisey@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 13 Dec 2007 13:07:03 -0800
Thanks for the response Tim.
1) Actually I work on an in house protocol converter that is configurable
between PS2, I2C and SPI that is used for testing prototype touch pads and
similar devices. We have our custom USB driver for it. The converter reports
itself as a proprietary device.
2) I generated timing data with a user mode app that handles interrupt
endpoint traffic from the driver.
3) I've tried to implement multiple pending IRPs in the driver but I'm not
sure I've implemented it correctly. I have introduced an exception during
surprise removal. I didn't write the original driver code and I have limited
driver experience.
To implement the multiple pending IRPs on the interrupt endpoint I simply
allocate multiple IRPs and associated URBs and call IoSetCompletionRoutine()
each one on startup. All IRPs and URBs are stored in the device extension
object.
The completion routine looks for the IRP in the device extension to
determine the URB. Then I process the incoming traffic and call
IoSetCompletionRoutine() on the IRP again.
4) On one computer it did not appear to change my timing results. I plan on
testing again to verify and test on another computer.
5) Question: Is is possible for this completion routine to be call with an
IRP that I did not explicitly create? I suspect not.
JR
"Tim Roberts" wrote:
J.R. Heisey <J.R. Heisey@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:.
1) The endpoint descriptor has a minimum value of 1 ms polling period.
Therefore it would seem that I can get a maximum of 1000 packets per
second with each packet containing a maximum of 64 bytes of payload
data.
Maximum throughput then limited to 64000 bytes per second.
Anyone disagree with this assessment?
No, assuming you are talking about a full-speed device, you are correct.
2) On some computers it appears that though my USB device requests 1 ms
interrupt endpoint polling the actual polling rate is 2 ms.
What leads you to conclude this? What device class? (Based on your
employer, I'm guessing it's a HID device...) Remember that the host
controller will not ask for data unless there is an outstanding read
request from some driver at the time the frame begins. If you are using a
custom driver, and it only queues one read request at a time, you'd see
this kind of behavior.
Does the behavior correspond to a particular type of host controller? We've
found that some USB host controllers simply suck.
--
Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.
- Follow-Ups:
- Re: USB interrupt endpoint limitations
- From: Tim Roberts
- Re: USB interrupt endpoint limitations
- From: David Craig
- Re: USB interrupt endpoint limitations
- References:
- Re: USB interrupt endpoint limitations
- From: Tim Roberts
- Re: USB interrupt endpoint limitations
- Prev by Date: Re: getting handle to device
- Next by Date: Re: USB interrupt endpoint limitations
- Previous by thread: Re: USB interrupt endpoint limitations
- Next by thread: Re: USB interrupt endpoint limitations
- Index(es):
Relevant Pages
|
Loading