1
\$\begingroup\$

I'm using a Microchip USB2517 7-port USB hub in a self-powered application, and I'm interested in the behaviour of the device if the upstream VBUS detect signal is removed. I'd like to know if the downstream VBUS is disabled when upstream VBUS is removed. The datasheet mentions that power to the differential pins must be removed when upstream VBUS is no longer detected. The datasheet isn't clear about the port power signal, however.

My reading of the USB 2.0 standard gives me an answer that's open to interpretation. From section 11.5, it's clear that the port enters the powered-off state when external power to the hub is removed. 11.5.1.2 says "If a hub was configured while the hub was self-powered, and then if external power is lost, the hub must place all ports in the Powered-off state." Unfortunately, it's not clear whether "external power" refers to the upstream VBUS detect signal being de-asserted, or whether it refers to the IC's external power (Vcc). Under the former interpretation, if there is no upstream devices the hub will not supply power to any downstream devices. Under the latter, the device will still supply some power (also not clear. One unit load? The negotiated number of unit loads? Without power on the differential pair, the device obviously can't request more than one unit load if plugged in after the fact.)

TL;DR: Is there any power available on the downstream ports of a self-powered hub if the upstream port isn't connected?

Related: Does USB Host always supply power on VBUS? (doesn't describe behaviour during powered-off state)

\$\endgroup\$

1 Answer 1

3
\$\begingroup\$

External power in case of hubs refers to external power adapter (or even a battery). If this is the only power to the hub, and it is a solo source of Vcc for hub controller IC, then it is obvious that downstream ports will have no power. The hub will be simply dead.

The confusion comes in cases when a hub has dual functionality and can derive the power either from external source, or from upstream VBUS, aka "power switching" hub. In accord with specifications, there should be some switch which gracefully replaces external power with VBUS power. When this happens, the hub must turn all downstream ports off. Also in this case all hubs must change the content of their descriptors from being "self-powered" to "bus-powered". Bus-powered hubs have power restrictions, so the host should know this, and apply corresponding power policy during re-enumeration process.

The question, however, is challenging. When VBUS is removed, the hub, as an any USB device, becomes "detached". USB specifications do not define behavior of devices in detached state, see Section 9.1.1.1. So this state is open to interpretations and up to designers.

One interpretation is that when a hub is not connected to bus, it is not attached, and and therefore cannot remain configured. As Section 11.13 says,

If a hub implements power switching, no power is provided to the downstream facing ports while the hub is not configured.

So, not configured = downstream VBUS is OFF. AFAIK, Microchip follows this interpretation when upstream VBUS is disconnected. There are other hubs with ports that can maintain VBUS, but they are called "charging ports" and are formally outside the USB framework. To support the logic of bus/self-powered switch, these chips have a special pin called LOCAL_PWR.

Hubs that don't use port power switching have VBUS on downstream ports all the time. I believe this is a violation of USB specifications, that's why you can't find the USB-IF certification logo on any cheap tiny hubs.

\$\endgroup\$
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.