Return to: App Notes Index
Several simple RS-232 interfaces have appeared in various magazine articles, built up on bipolar transistor circuits, but most have several shortcomings. The circuit shown here, however, is small, simple, inexpensive, compatible with the RS-232 standard (re voltage levels and also in having inverters in both RxD and TxD pathways), and works in full-duplex operation, which most simplified interfaces do not.
The circuit "steals" its negative voltage from the host serial port, and draws no power when not in operation (except for transistor leakage currents), so it is useful for low-power applications. It costs approximately $1, about 1/3 the cost of a MAX232 interface, and saves the 5 mA quiescent current draw of that device.
The circuit is based on that used in the Parallax BS2. Q1 is the receive inverter, and Q2 the transmit inverter. TxD and RxD go to the host serial port and have RS-232 compatible levels (+5, -12v), while Tc and Rc go to the local cpu with 0 & 5V levels. By adding diode D1 and capacitor C1 to the Parallax circuit, we get one where C1 charges to the -12 volts or so on the RxD line and holds it during positive RxD transitions, effectively isolating the TxD and RxD lines, and allowing normal full-duplex operation. Most general-purpose bipolar transistors should work here, and resistor values are not critical - values 2-5x larger should work fine, except for RN1c. For RN1 and RN2, we use 3-resistor SIP networks for easy layout. We have used this circuit consistently at baudrates to 115,200 through 12' foot cables.
Further, for networking applications, the TxD and RxD channels of several of these circuits can be wired "unmodified" in parallel. In this case, however, the Q2 inverter can load down the network if the circuit driving Q2 is unpowered, but insertion of diode D2 between Q2's collector and RN1c (in place of the wire) will prevent this problem. Also, if more than a couple of these circuits are tied together, RN1c, D1, and C1 can be removed from all but one circuit, in order to reduce costs as well as lower the current it takes to drive the TxD line.
file: /Techref/net/qwest/users/www/http/~oricom/an-ecd02/AN-ECD02.HTM, 3KB, , updated: 2001/5/25 13:41, local time: 2024/11/26 03:17,
3.137.169.14:LOG IN
|
©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? <A HREF="http://massmind.org/techref/net/qwest/users/www/http/~oricom/an-ecd02/AN-ECD02.HTM"> AppNote AN-ECD02</A> |
Did you find what you needed? |
Welcome to massmind.org! |
Welcome to massmind.org! |
.