About usb hub

Dear All,

I have an USB reader, The cost is 60 seconds for write some data when connect it to PC, But the cost is 20 seconds only when connect it by USB 2.0 HUB, Why?

B.R.
Allen

Did you connect the hub to the PC port to which you get the 60s result?
May be other devices connected to the root hub on which the pc port located?

Dear All,
I have an USB reader, The cost is 60 seconds for write some data when connect it to PC, But the cost is 20 seconds only >when connect it by USB 2.0 HUB, Why?
B.R.
Allen


NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

xxxxx@sina.com wrote:

Dear All,

I have an USB reader, The cost is 60 seconds for write some data when connect it to PC, But the cost is 20 seconds only when connect it by USB 2.0 HUB, Why?

B.R.
Allen


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

Hi,

this could be a hardware problem caused by an impedance mismatch. Cheap
USB devices are often not perfect. Try a passive extension cable between
the PC and the reader to see if it gets better. I have an USB stick,
that works only if connected through an extension cable. Beside transfer
retries an USB 1.1 connect could be another reason. But usually this
results in a much larger difference.

Regards
Thomas

allen zhang wrote:

I have an USB reader, The cost is 60 seconds for write some
data when connect it to PC, But the cost is 20 seconds only
when connect it by USB 2.0 HUB, Why?

What method of data transfer are you using? Control, bulk, isochronous? Also, is the device USB 1.1?

I’ve seen this myself where introducing a USB 2.0 hub in series with a USB 1.1 device upped the speed quite a bit, but this was when I was issuing a ton of endpoint zero control requests. I chalked it up to the fact that the 1.1 device was now talking to the 2.0 drivers (usbehci, etc.), which maybe were faster than the UHCI/OHCI drivers in this regard.

> USB devices are often not perfect. Try a passive extension cable between

the PC and the reader to see if it gets better. I have an USB stick,
that works only if connected through an extension cable.

Beware of this.

Passive extension cables are banned by the spec, and I have several hardware items (like the video camera) around me which fail if connected by such a cable.


Maxim S. Shatskih
Windows DDK MVP
xxxxx@storagecraft.com
http://www.storagecraft.com

Thank you chang pei,

Did you connect the hub to the PC port to which you get the 60s result?
No, I cann’t connect the hub to the PC port.
May be other devices connected to the root hub on which the pc port located?
No, I cann’t connect the other devices to the root hub.
I test it connect my devcie only.

Allen

Thank you Thomas,
I’ll check the reason about impedance.

B.R.
Allen

Thank you Chris Aseltine

What method of data transfer are you using? Control, bulk, isochronous? Also, is the device USB 1.1?
The method of data transfer is bulk, It is use USB 1.1,

There are tow interfaces/endpoints for my reader, one for IN, the other for OUT.
So The interface will be switched by SET_INTERFACE request, I found the costs are different.
There is 0.227ms with USB HUB, There is 3.028ms with root hub.

Best Regards,
Allen

xxxxx@sina.com wrote:

> What method of data transfer are you using? Control, bulk, isochronous? Also, is the device USB 1.1?
The method of data transfer is bulk, It is use USB 1.1,

There are tow interfaces/endpoints for my reader, one for IN, the other for OUT.
So The interface will be switched by SET_INTERFACE request, I found the costs are different.
There is 0.227ms with USB HUB, There is 3.028ms with root hub.

Interesting. Why do you use two interfaces, if they’re being handled by
the same driver?


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

so, I thinks you get a 1.1 port, when you connect usb storage(which may be 2.0) to it, you will only get 1.1 speed. And of course, your hub is 2.0(which connected to another 2.0 port) and you get a 2.0 speed from that.

Thank you chang pei,
Did you connect the hub to the PC port to which you get the 60s result?
No, I cann’t connect the hub to the PC port.
May be other devices connected to the root hub on which the pc port located?
No, I cann’t connect the other devices to the root hub.
I test it connect my devcie only.
Allen


NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

Thank you Tim Roberts,

Interesting. Why do you use two interfaces, if they’re being handled by
the same driver?
There is an old product, We should be remain the configuration for compatible, it can be passed for DTM testing.

Thank you chang pei,

so, I thinks you get a 1.1 port, when you connect usb storage(which may > be 2.0)
to it, you will only get 1.1 speed. And of course, your hub is 2.0(which
connected to another 2.0 port) and you get a 2.0 speed from that.
Root Hub is usb 2.0 compatible too, Why it is slower?
By the way, Is it asynchronous by usb hub? Where I can get the more details inforamtion? Thank you

B.R.
Allen

xxxxx@sina.com wrote:

> Interesting. Why do you use two interfaces, if they’re being handled by
> the same driver?
There is an old product, We should be remain the configuration for compatible, it can be passed for DTM testing.

The answer occurred to me in the shower this morning, as do most of my
flashes of insight.

If you are handling both interfaces in a single driver, as a composite
device, then you do not need to switch between the interfaces. Just
include all of the interfaces when you make your
URB_FUNCTION_SET_CONFIGURATION call. That way, you can refer to any of
the endpoints at any time.

Remember that interfaces are nothing more than a convenient software
mechanism for grouping the endpoints. All of the endpoints in a
configuration are available at all times. The interface number is not
even part of the USB packet – only the endpoint number is.

The only time you really NEED to do URB_FUNCTION_SET_INTERFACE is when
you want to change the alternate setting. If you don’t use alternate
settings, then you don’t ever need to SET_INTERFACE.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

Thank you Tim Roberts,

Yes, It doesn’t switch interface, one interface/configuration for tow endpoints are good idea, There are two interfaces for the old version firmware, there is the reason why switch the interface between IN/OUT endports.

B.R.
Allen

xxxxx@sina.com wrote:

Thank you Tim Roberts,

Yes, It doesn’t switch interface, one interface/configuration for tow endpoints are good idea, There are two interfaces for the old version firmware, there is the reason why switch the interface between IN/OUT endports.

I think you missed my point, although I’m not entirely sure.

You don’t need to switch interfaces, even if you have two interfaces.
You can make BOTH interfaces active at the same time when you do your
URB_FUNCTION_SET_CONFIGURATION call. When you do that, all of the
endpoints in BOTH interfaces can be used at any time, without switching.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

Thank you Tim Roberts,

It looks that we should be modify the firmware and the driver at the same time.
The status registers be setted by set_interface in the old version firmware.

B.R.
Allen