This schematic facilitates switching a printer’s USB link between a computer and a laptop. The objective was to provide a mechanism for a laptop to periodically utilize the printer while, in all other instances, the printer would be connected to the computer. Instead of manually disconnecting the printer from the computer and subsequently connecting it to the laptop, this circuit implements automatic USB connection switching. K1 and K2 represent standard Type-B USB receptacles, and K3 serves as a USB Type-A port.
The USB cable originating from the laptop is inserted into K2, while the computer’s USB cable is connected to K1. A USB cable originating from K3 connects the printer to this circuit. The connection from the computer remains consistently plugged in, and the connection from the laptop is established only when the laptop requires printing. Under normal operation, the laptop is not connected to K2, so the USB signal directed towards the printer originates from the computer via K1, through the normally closed contacts of relay Re1, to K3 and subsequently to the printer.
Whenever the laptop is connected, the presence of the 5-volt power signal on its USB port causes Re1 to shift over to the printer’s connection to K2 and the laptop. Disconnecting the laptop returns control of the printer back to the computer. The circuit was evaluated on a USB 1.1 compliant printer and a computer and laptop featuring USB-2.0 high-speed ports. The Printed Circuit Board (PCB) traces for D+ and D– should be maintained at minimal length, and ideally, they should have the same length.
The relay should be a low-power type (5 V at 100 mA coil current) with two changeover (c/o) contacts. Switch S1 is only required when the two computers to choose between are permanently present and connected to the circuit. The switch then selects the computer having access to the printer.
A relay is an electrically operated switch. It allows a small control signal to control a larger electrical circuit. In this circuit, relay Re1 acts as the switching element, directing the USB signal to either the computer or the laptop. Relays are commonly used to isolate circuits and prevent damage to sensitive electronics. They operate based on the principle of electromagnetism: an electric current flowing through a coil creates a magnetic field, which then activates a switch, allowing current to flow through the connected circuit. This technology is frequently used in various applications, including automotive systems, industrial control, and communication equipment, offering reliable switching capabilities with minimal electrical contact.