Protecting RS-232 Lines
by Nathan Rector
"Equipment is only as strong as the weakest part in it's whole." This axiom has always been applied to mechanical machines, but has never really been thought about when addressing computer equipment. As a result many areas of a computer system have never had adequate protection or maintenance.
The weakest parts of any computer system in the Multi-Value arena are its data lines; specifically the RS-232 lines that most systems still use to connect to terminal and printers.
The RS-232 communication standard was originally developed to connect communication equipment to a computer. In those cases, the cable was hardly more than 3 ft. Now days, RS-232 cables used to connect devices are anywhere from 3 ft to 300 ft.
An RS-232 cable needs a minimum of receive and send lines, handshaking lines, and a common reference. The common reference line was designed to provide a common reference point among 2 devices. This allowed the voltage being used on the send and receive lines to be the same between the connecting equipment.
The common reference line work well when the cable is short, but as the cable gets longer, resistance in the wire and the potential for static to collect, makes the common reference less reliable. The less reliable this common reference is, the high potential the cable will transmit unreliable data or damaging surges.
In last issue of Spectrum ("Does your UPS protect you?" Nov/Dec 96), I introduced the dangers of "Inter-system ground noise". RS-232 lines are very vulnerable to "Inter-system ground noise." This is due to RS-232 cables manufactured and/or installed incorrectly. Either of these can result in electrical feedback causing damage to your computer hardware as well as unpredictable results.
RS-232 lines are used often in large computer installation since they are inexpensive and easy to make and install. They work well for what they are designed to do, but there are some guidelines to follow when working with RS-232 line that help prevent damage to your hardware.
* Keep cables are short as possible. The longer the cable gets, the larger the potential it will cause problems.
* Connect all computer equipment to the same UPS system. This is often impracticable due to the location of the various terminals and printers your system uses. The next best thing is to connect all computer equipment to the same electrical circuit. This keeps your computer equipment from using different ground references.
Contrary to what many UPS manufactures say, an UPS will not prevent "Inter-system ground noise." The only way an UPS helps in preventing "Inter-system ground noise" is by preventing "Common-mode noise." "Common-mode noise" is the most common cause of "Inter-system ground noise," but not the only. These two types of ground noise are separate entities, although they are sometimes relate to each other.
* DO NOT connect any motor driven equipment such as fans, air conditioners, saws, or refrigeration equipment to the same electrical circuit as your computer equipment. These types of equipment produce large amounts of electrical noise that is injected into the ground wire producing "Ground Noise" and "Common-mode Noise".
If your computer equipment (this includes terminals and printers) is connected to the same circuit and not protected by UPS, they will transmit this noise into your RS-232 lines.
* Keep RS-232 lines as far from motor driven and medical equipment as possible. Motor driven, as well as most medical equipment produce magnetic fields that will corrupt data or produce garbage in RS-232 lines.
The problems these types of equipment cause are many times hard to isolate. For example, Saws are many times used in irregular intervals. Same with X-ray machines and CAT scans. Since they aren't being run constantly, it makes it hard to find what equipment is causing problems with the RS-232 line.
* Avoid running RS-232 cable between buildings. You will always find that the ground references will be different from one building to the next. If you have to run the cable between buildings, do so underground. If they are left in the open, they will attract lightning and other electric and RF (radio frequency) interference.
If this still can't be avoided, then supply surge suppressers on both ends of the cable as a minimum requirement. The best thing to do is use Fiber Optics between buildings.
The alternate to Fiber Optics is optical Isolators. These devices come in 2 forms; as an independent device or built into short-haul modems or other data line drivers and converters.
Optical Isolators are a step up from a surge suppresser. They briefly turn the electrical currents from the cable into light, and then back again. This keeps any surges from being passed on.
Short-haul modems, and other data line drivers and converters, are used to either extend the length of an RS-232 line beyond the 300 ft maximum or to provide better data protection in industrial areas caused by electrical and RF interference.
* Make sure your wiring is correct. Many people make their own RS-232 wires and fail to connect pin 1. The minimum requirement to make a RS-232 run is Pin 1 (ground), 2 (transmit), 3 (receive), and 7 (signal ground). Pin 7 is the wire the computer uses to decide what the common voltage to use between pins 2 and 3.
Pin 1 is used to filter out spikes in pin 7 by supplying a second reference point for pin 7 to use. If pin 1 has not been connected, then the computer doesn't know how to filter the incoming voltage differences on pin 7 and assumes it is the correct voltage to use.
As you can see, RS-232 cables are the weakest part of your computer system. They are often placed in environments that the cable was not designed for or made incorrectly. If you follow these guidelines, you can cut down on damage RS-232 lines can cause in your computer system.