Add A Dual-Port COM Switch To Your PC

Did you ever wish you had another COM port on your PC without needing an additional COM card? This article describes a simple RS-232 electronic switch that splits one COM port into two. By...
March 22, 1999
2 min read

Did you ever wish you had another COM port on your PC without needing an additional COM card? This article describes a simple RS-232 electronic switch that splits one COM port into two. By toggling the RTS hardware line, the Dual Port COM Switch circuit will electronically switch between two devices connected to a single COM port.

RS-232 transmit, receive, and RTS from the PC connect to the Dual Port COM Switch circuit via connection to IC-1 (see the figure). IC-1 is a MAX232A RS-232-to-TTL converter chip with an onboard ±10-V charge-pump power supply. The transmit line and RTS line from the PC are converted to TTL logic levels via IC-1. If the RTS line is set to logic HIGH, it will pass the converted TTL transmit signal to IC-2 via the NAND gate IC-4. IC-2, another MAX232A chip, then conditions the TTL transmit signal back to the appropriate RS-232 driver voltages for the device connected to Port B. The receive signals from Port B, in turn, also are NAND-gated, via IC-4, back to IC-1 and the PC.

A logic level LOW on the RTS line routes the transmit and receive signals in a similar fashion to and from the PC and Port A. Indicator lights LED1 and LED2 provide a simple visual indication of which port is active.

Switching between Port A and Port B, using Microsoft Visual Basic, is a simple matter of setting the COM control’s RTS property to True or False:

COM.RTS = True ;connect PC to Port B
COM.RTS = False ;connect PC to Port A

The switch is activated using Microsoft QuickBasic (see the listing).

About the Author

Sign up for Electronic Design Newsletters
Get the latest news and updates.

Voice Your Opinion!

To join the conversation, and become an exclusive member of Electronic Design, create an account today!