USB is becoming increasingly popular as an interface in industrial systems for human-machine interactions, diagnostics, firmware downloads, connections of peripherals and data-logging. Given the presence of noise and harsh transients present in the industrial world, as well as for electrical safety, systems designers prefer to isolate the USB port. Having one USB port that can connect to both a host (such as a laptop) or a peripheral (such as a USB drive), instead of separate ports for host and peripheral connections increases flexibility and reduces costs.
USB On-the-Go (OTG) offers this flexibility, while also allowing host and peripheral roles to be swapped through Host Negotiation Protocol (HNP). However, there is no solution available currently to isolate an USB OTG port. In this article, the key considerations on implementing an isolated USB OTG port with HNP and the corresponding requirements from an isolated USB repeater are described, along with an application diagram and test results implementing Isolated USB OTG port with TI’s ISOUSB211 isolated USB repeater.
Existing approach for implementing isolated USB platforms have been with recommendations around providing dedicated host and peripheral ports for establishing the datalink as shown in #FIG_R45_JK1_MVB. The upstream-facing (peripheral) port has the D+ pulled up (indicating a full or high-speed peripheral) or D- pulled up (indicating a low-speed peripheral) through a 1.5-kΩ resistor. The downstream facing (host) device has the 15-kΩ pull-down resistors as per USB2.0 standard. Downstream-facing port powers the 5-V VBUS rail and does not draw power from the upstream facing port. Once the connect is established, the presence of VBUS is detected after which pullup identification and packet transactions occur. Therefore, for an isolated OTG implementation in which the port must assume either a host or a peripheral role, the isolator must be transparent to the connection.
OTG ports have an additional fifth pin tagged as the ID pin. The status on this ID pin governs the initial host and peripheral roles when the connect occurs, as shown in #FIG_JVZ_RK1_MVB. The port connected to the cable end with ID shorted to ground assumes the initial host (A-device) role and the device connected to the other end of cable with ID left floating assumes the initial peripheral role (B-device). The ID pull-up on the OTG module helps determine the status of ID pin on connect. In a situation where the B device wants to take over the host role, OTG defines an HNP that enables devices to exchange roles seamlessly without unplugging and exchanging the cable connections. For HNP to work seamlessly, the isolated USB repeater should have the ability to switch any side to be upstream- or downstream-facing on the fly. The Session Request Protocol that enables the initiation of sessions on the A device by pulsing on the VBUS is not a topic that is covered in this article.
#FIG_OBQ_XK1_MVB shows that the isolated repeater needs to have flexibility for any side to operate as host or peripheral. During operation, the isolated repeater introduces a 15-kΩ pull down at power up. The side that provides the external 1.5-kΩ pull up will establish the connect. The other side, which assumes the host role, introduces the internal 1.5-kΩ pull up in the repeater to mirror the downstream connect. The end plugged in with the micro-A plug takes on the initial A-device role and the end plugged in with the micro-B plug assumes the initial B-device role. After the initial role assignment, HNP has a defined set of transitions in a scenario where the devices wish to exchange roles: the initial A-device suspends the bus and initial B-device transitions to wait-for-connect state by disconnecting the 1.5-kΩ pull up and enabling the 15-kΩ pull down. As the lines are now in SE0 state, the A-device takes up the peripheral role and establishes a connect by enabling its internal 1.5-kΩ pull up resistor. The bus now reflects a J-state which gets detected as a peripheral connect by the initial B-device, which now assumes the host state. The 5-V VBUS is sourced by A-device, irrespective of the roles determined by HNP.