Design Considerations for RS-232 Interfaces Design Note 27 Sean Gold Table 1 key RS-232 Transceiver Specifications (EIA RS232C.V28) SPECIFICATIONS Signal Levels Cable Length Load Capacitance Cable Termination Data Rate Slew Rate Fault Conditions VALUE ±15 Max; ±5 Min 50 Max 2500 Max 3k<R<7k 20k Max 3<SR<30 Drivers Must Tolerate: • Conductor to Conductor Shorts • Line Open Circuit • ±25V Line Overage UNITS V Ft pF Ω Baud V/μs — — — Power Supply Generators Creating the separate RS-232 voltage levels is a common problem in systems which have only a 5V logic supply. Linear Technology has developed a family of transceivers that include an on-chip charge pump to generate the RS-232 supplies. These transceivers are available in a wide variety of configurations incorporating up to 5 drivers and 5 receivers. Some transceivers have a SHUTDOWN control which turns off the charge pump and places the drivers in a “zero” power–high impedance state. The charge pump consists of a relaxation oscillator, a capacitive voltage doubler, and a capacitive voltage inverter. The oscillator is designed to operate at a frequency well above the signal frequencies to avoid 10/89/27_conv supply degradation as charge is rapidly removed from the storage capacitors. The LT®1180/LT1181’s charge pump oscillator operates at approximately 200kHz, which is two times the frequency of the LT1080 and LT1130 series transceivers. The faster oscillator permits the use of low value capacitors (C>0.1μF), and shortens the turn-on time from power off or SHUTDOWN state to less than 200μs. The LT1080 and LT1130 start up in approximately 2ms. Load Driving It is often desirable to exceed the 20kHz data rate or drive loads greater than 2500pF, e.g. long cables. Slew rate control in the drivers makes this objective possible without compromising the remaining specifications. When lightly loaded, the slew rate is set by an internal bias current and compensation capacitor. When heavily loaded, slew rate is limited by the output stage short circuit current and the load capacitance. The plot in Figure 1 shows the maximum load capacitance for a given data rate. L, LT, LTC, LTM, Linear Technology and the Linear logo are registered trademarks of Linear Technology Corporation. All other trademarks are the property of their respective owners. MAXIMUM LOAD CAPACITANCE pF (THOUSANDS) Introduction When designing an RS-232 interface, it is necessary to conform to standards published by the Electronics Industry Association, EIA RS-232.V28. Some key specifications are summarized in Table 1. However, the EIA specifications are often just the beginning of the design. Practical problems such as generating RS-232 signal levels, providing sufficient load drive, and ensuring protection against fault conditions must also be considered. 5.4 5.2 LT1180 5.0 4.8 4.6 LT1080 4.4 4.2 4.0 3.8 3.6 3.4 3.2 3.0 20 40 60 80 100 FREQUENCY (kHz) DN027 F01 Figure 1. Max Load Capacitance vs Data Rate. Both Transceivers Use 1.0μF Storage Capacitors PULSE ENGINEERING #PE-63394 MUR120 VOUT = 5V + 7 • 1 3.6kΩ* SYSTEM SUPPLY VIN = 3.5V – 15V + 0.1μF 5 220μF 100μF 6 • 100kHz LOGIC INPUT TO OPTOCOUPLER 0 5 MUR120 VIN 10 VSW LT1072 500Ω SECONDARY VOUT ADJUST 10kΩ 1μF + 1μF RS232 LINES 1 2 LT1130 28 V 27 3 26 4 25 5 24 6 23 7 22 8 21 9 20 10 19 11 18 12 17 13 16 14 15 + + GND Q1 VN2222 1μF –10 DN027 F02b SHUTDOWN RS232 Driver Signals – 1μF + V+ 1μF LT1130 DRIVER OUTPUT 0 VFB VC 380Ω AT VIN = 5V (NOTE 2) 2.8kΩ† LOGIC INPUT 6N136 5 100kHz RS232 INPUT 0 NOTE 1 –5 380Ω 2.8kΩ† 5 OPTOCOUPLER OUTPUT LOGIC OUTPUT 6N136 0 = SYSTEM GROUND DN027 F02b DN027 F02a RS232 Receiver Signals = FLOATING COMMON NOTE 1: REPEAT THE OPTOCOUPLER CONNECTIONS FOR EACH LINE. NOTE 2: SELECT FOR 10mA THROUGH LED. *FOR IMPROVED EFFICIENCY, REPLACE THE 3.6kΩ RESISTOR WITH A 30V ZENER DIODE. †INCREASE COLLECTOR RESISTANCE WITH USING OPTOCOUPLERS WITH LOWER CURRENT TRANSFER RATIO. Figure 2. 2500V Isolated 5-Driver/5-Receiver RS232 Transceiver Fault Conditions In addition to protecting against all of the fault conditions described in Table 1, LTC transceivers are guaranteed for latchup free operation. When the drivers are turned off or SHUTDOWN, the output stage becomes high impedance; even when the output is pulled beyond the supply rails. The small current produced by overvoltage is not directed back into the supplies. High impedance on the driver outputs also eliminates signal feedthrough between the logic inputs and the RS-232 lines. When the device is turned on, overvoltage can, at most, pull the limited short circuit current from the supplies. The receivers are also short circuit current limited to prevent damage to unprotected logic circuitry. Isolated Transceiver The most frequent cause of failure in interface chips is exposure to extreme fault conditions. Protection against large differences in ground potential, high ground loop currents, or accidental high voltage connections mandates a fully isolated transceiver. supplies on both sides of the isolation transformer. High speed 6N136 optocouplers permit the LT1130 to operate at its full 100kHz bandwidth. However, slower, less expensive optoisolators, such as the 4N28, may be used when the data rate is less than 20k baud. The 5V power supply is generated with an isolated LT1072 switching regulator. The LT1072 has no electrical connection to the load; instead, the circuit derives its feedback from the transformers flyback voltage. This technique is often referred to as an isolated flyback regulator1. The regulator needs to deliver only modest current levels (200mA max), allowing a physically small isolation transformer. The circuit accepts 3.5V to 15V unregulated inputs which are readily available in most systems. Load regulation is 5% over a 200mA range of output current (50mA-250mA), and efficiency reaches 60% under maximum load conditions. Efficiency may be improved by 10% if the 3.6kΩ snubber resistor is replaced with a 30V Zener diode. Q1 provides shutdown control, which disables the interface to a low power state. Note 1: Refer to Linear Technology’s Application Note 19, pp. 30-34. The circuit in Figure 2 provides 2500V isolation with optically coupled data lines and an isolated 5V supply. A powered transceiver eliminates the need for three Data Sheet Download www.linear.com Linear Technology Corporation For applications help, call (408) 432-1900 dn27f_conv IM/GP 0889 165K • PRINTED IN THE USA 1630 McCarthy Blvd., Milpitas, CA 95035-7417 (408) 432-1900 ● FAX: (408) 434-0507 ● www.linear.com © LINEAR TECHNOLOGY CORPORATION 1989