RS-232

In telecommunications, RS-232 (sometimes also referred to as EIA RS-232C) is a standard for serial binary data interconnection between a DTE (Data terminal equipment) and a DCE (Data communication equipment). It is commonly used in computer serial ports. A similar ITU-T standard is V.24.

Internet protocol suite   edit  (https://academickids.com:443/encyclopedia/index.php?title=Template:IPstack&action=edit)
Application layer HTTP, HTTPS, SMTP, FTP, UUCP, NNTP,
SSH, IRC, SNMP, SIP, RTP, Telnet ,...
Transport layer TCP, UDP, SCTP, DCCP, ...
Network layer IPv4, IPv6, ICMP, ARP, IGMP, ...
Data link layer Ethernet, Wi-Fi, Token ring, FDDI, PPP, ...
Physical layer RS-232, EIA-422, RS-449, EIA-485...
Contents

Scope of the standard

The EIA standard RS-232-C as of 1969 defines:

  • Electrical signal characteristics such as voltage levels, signaling rate, timing and slew-rate of signals, voltage withstand level, short-circuit behavior, maximum stray capacitance and cable length
  • Interface mechanical characteristics, pluggable connectors and pin identification
  • Functions of each circuit in the interface connector
  • Standard subsets of interface circuits for selected telecomm applications

The standard does not define such elements as character encoding (for example, ASCII, Baudot or EBCDIC), the framing of characters in the data stream (bits per character, start/stop bits, parity). The standard does not define bit rates for transmission, although the standard says it is intended for bit rates less than 20,000 bits per second. Some types of equipment exceed this speed while still using RS-232 compatible signal levels.

History

This standard was originally used for specifying the connection between a teletypewriter, which used asynchronous communication and electromechanical components, with a modem. When electronic terminals (smart and dumb) began to be used, they were often designed to be interchangeable with teletypes, and so supported RS-232. The C revision of the standard was issued in 1969 in part to accommodate the electrical characteristics of these devices. Then, because it was there, it was used for all sorts of remote communications, especially through modems, including computer to computer.

Since application to such devices as computers, printers, digitizer tables, test instruments, and so on were not envisioned, designers implementing an RS-232 compatible interface on their equipment often interpreted the requirements idiosyncratically. Common problems were non-standard pin assignment of circuits on connectors, and incorrect or missing control signals. The lack of adherence to the standards produced a thriving industry of breakout boxes, patch boxes, test equipment, books, and other aids for the connection of disparate equipment.

Later personal computers (and other devices) started to make use of the standard so that they could connect to existing equipment. The IBM Selectric typewriter with RS-232 supplanted teletypes in some applications. For many years some form of RS-232-compatible port was a standard feature for serial communications on almost all computers. It remained in widespread use into the late 1990s. For much of this time it was the standard way to connect modems.

One exception is mainframe computers. These large systems generally have specialized I/O processors for communication with terminals. For instance, some IBM mainframes had a Telecommunication Control Unit (TCU) attached to their multiplexer channel. The TCU would support multiple terminals, sometimes hundreds. Many of these TCUs could support RS-232 when it was required, although usually there were other serial interfaces.

The standard continues to be revised and updated by the EIA and since 1988 the Telecommunications Industry Association (TIA[2]). Revision C was issued in a document dated August 1969. Revision D was issued in 1986. The current revision is TIA-232-F, Interface Between Data Terminal Equipment and Data Circuit-Terminating Equipment Employing Serial Binary Data Interchange, issued in 1997. Changes since Revision C have been in timing and details intended to improve harmonization with the CCITT standard V.24, but equipment built to the current standard will interoperate with older versions.

The original letters "RS" stood for "Recommended Standard" according to a long-time member of the working group TR30.2 of EIA/TIA.

Limitations of the standard

Because the application of RS-232 has extended far beyond the original purpose of interconnecting a terminal with a modem, successor standards have been developed to address the limitations. Issues with the RS 232 standard include:

  • The large voltage swings and requirement for positive and negative supplies increases power consumption of the interface and complicates power supply design. The voltage swing requirement also limits the upper speed of a compatible interface.
  • Single-ended signalling referred to a common signal ground limit the noise immunity and transmission distance.
  • Multi-drop (meaning a connection between more than two devices) operation of an RS-232 compatible interface is not defined; while multi-drop "work-arounds" have been devised, they have limitations in speed and compatibility.
  • Asymmetrical definitions of the two ends of the link make the assignment of the role of a newly developed device problematical; the designer must decide on either a DTE-like or DCE-like interface and which connector pin assignments to use.
  • The handshaking and control lines of the interface are intended for the setup and takedown of a dial-up communication circuit; in particular, the use of handshake lines for flow control is not reliably implemented in many devices.
  • While the standard recommends a connector and pinout, the connector is large by current standards.

Role in modern computing

In the book "PC 97 Hardware Design Guide" [1], Microsoft deprecated support for the RS-232 compatible serial port of the original IBM PC design. Today, RS-232 is gradually being superseded in personal computers by USB for local communications. USB is faster, has connectors that are simpler to connect and use, and has software support in Microsoft operating systems. This is why many PCs intended for office use often ship with 'legacy-free' motherboards without any RS-232 serial ports. However, RS-232 is still quite common in point-of-sale (cash drawers, barcode and magnetic stripe readers) and industrial (measurement and remote-control devices) peripherals, so computers made for such applications are still equipped with RS-232 ports either 'on-board', or on a separate PCI or ISA card. As an alternative, USB docking ports are available which can provide connectors for PS/2 keyboard, PS/2 mouse, one or more serial ports, and one or more parallel ports.

Standard details

In RS-232, data is sent as a time-series of bits. Both synchronous and asynchronous transmission are supported by the standard. The standard does not define character framing within the data stream, or character encoding.

Voltage levels

The RS-232 standard defines the voltage levels that correspond to logical one and logical zero levels. Signals are plus or minus 3 to 15 volts. The range near zero volts is not a valid RS-232 level; logic one is defined as a negative voltage, the signal condition is called marking, and has the functional significance of OFF. Logic zero is positive, the signal condition is spacing, and has the function ON. The standard specifies a maximum open-circuit voltage of 25 volts; signal levels of ±5V, ±10V, ±12V, and ±15V are all commonly seen depending on the power supplies available within a device. Circuits driving an RS-232-compatible interface must be able to withstand indefinite short circuit to ground or to any voltage level up to 25 volts. The slew rate, or how fast the signal changes between levels, is also controlled.

Connectors

RS-232 devices may be classified as Data Terminal Equipment (DTE) or Data Communications Equipment (DCE); this defines which wires will be sending and receiving each signal. The standard recommended but did not make mandatory the common D-subminiature 25-pin connector. In general, computers and terminals have DTE connectors and modems and printers have DCE connectors. However, these definitions are not always adhered to strictly; it is often necessary to consult documentation, test connections with a breakout box, or use trial and error to find a cable that works.

Presence of a 25-pin D-sub connector on a piece of equipment does not indicate presence of an RS 232 C compliant interface. For example, on the original IBM PC, a male D-sub was an RS-232-C DTE port (with a non-standard current loop interface on reserved pins), but the female D-sub connector was used for a parallel Centronics printer port. Some early personal computers put non-standard voltages or signals on their serial ports.

The standard specifies 20 different signal connections. Most of these pins were unused by many devices, however, so it was common for machines to save money and space by using smaller connectors, notably the 9-pin D-sub DE-9 connector used by most PC's since the IBM PC AT as well as many other devices. DB-25 and DE-9 connectors on most devices are female, but this is not universal. More recently, 8 pin RJ-45 connectors have become common, although pin assignments vary widely. Standard EIA/TIA 561 specifies a pin assignment, but the "Yost Serial Device Wiring Standard" invented by Dave Yost is common on Unix computers, and many devices don't follow either of these.

The following table lists the commonly used RS-232 signals and common pin assignments:

Signal DB-25 DE-9 EIA/TIA 561 Yost
Common Ground 7 5 4 4,5
Transmitted Data (TD) 2 3 6 3
Received Data (RD) 3 2 5 6
Data Terminal Ready (DTR) 20 4 3 2
Data Set Ready (DSR) 6 6 1 7
Request To Send (RTS) 4 7 8 1
Clear To Send (CTS) 5 8 7 8
Carrier Detect (DCD) 8 1 2 7
Ring Indicator (RI) 22 9 1 -

The signals are labeled from the standpoint of the DTE device; TD, DTR, and RTS are generated by the DTE and RD, DSR, CTS, DCD, and RI are generated by the DCE. The ground signal is a common return for the other connections; it appears on two pins in the Yost standard but is the same signal. Connection of pin 1 (protective ground) and pin 7 (signal reference ground) is a common practice but not recommended. Use of a common ground is one weakness of RS-232. If the two pieces of equipment are far enough apart or on separate power systems, the ground will degrade between them and communications will fail; this is a difficult condition to trace.

Note that EIA/TIA 561 combines DSR and RI, and the Yost standard combines DSR and DCD.

Cables

Because of the variation and inconsistencies of RS-232 implementations, it is not always easy to determine the proper cable for connecting two devices. Connecting a DCE device and a DTE device with the same types of connectors requires a straight cable with appropriate ends. "Gender changers" are available to solve gender mismatches between cables and connectors. Connecting devices with different types of connectors requires a cable that connects the corresponding pins according to the table above. Cables with 9 pins on one end and 25 on the other are common, and manufacturers of equipment with RJ-45 connectors usually provide and appropriate cable with either a DB-25 or DE-9 head (or sometimes interchangeable heads so they can work with multiple devices).

Connecting two DTE devices together requires a null modem that acts as a DCE between the devices by swapping the corresponding signals (TD-RD, DTR-DSR, and RTS-CTS). This can be done with a separate device and two cables, or using a cable wired to do this. One feature of the Yost standard is that a null modem cable is a "rollover" cable that just reverses pins 1 through 8 on one end to 8 through 1 on the other end (not to be confused with an Ethernet crossover cable, which is wired very differently).

For configuring and diagnosing problems with RS-232 cables, a "breakout box" may be used. This device normally has a female and male RS-232 connector and is meant to attach in-line; it then has lights for each pin and provisions for interconnecting pins in different configurations.

RS-232 cables may be built with connectors commonly available at electronics stores. The cables may be between 3 and 25 pins; typically 4- or 6-pin wires are used. Flat RJ (phone-style) cables may be used with special RJ-RS232 connectors, which are the easiest to configure.

The reason that a minimal two-way interface can be created with only 3 wires is that all the RS-232 signals share a common ground return. The use of unbalanced circuits makes RS-232 susceptible to problems due to ground potential shifts between the two devices. RS-232 also has relatively poor control of signal rise and fall times, leading to potential crosstalk problems. RS-232 was recommended for short connections (15 meters or less). RS-232 interface cables are not usually constructed with twisted pair because of the unbalanced circuits.

While the control lines of the RS 232 interface were originally intended for call setup and takedown, other "handshakes" may be required by one or the other device. These are used for flow control, for example, to prevent loss of data sent to a serial printer. For example, pin 20 is commonly used to indicate "device ready". Pins may also be "jumpered" or routed back within the connector. For example a pin saying "are you ready?" from device A might be wired to the pin saying "I'm ready" on device A if device B did not transmit such a signal. Common handshake pins are 20, 8, 4, and 6.

Related standards

Other serial signalling standards may not interoperate with standard-compliant RS 232 ports. For example, using the TTL levels of +5 and 0 V puts the mark level in the forbidden undefined area of the standard. Such levels are sometimes used with NMEA-compliant GPS receivers and depth finders.

20mA current loop uses the absence of 20mA current for high, and the presence of current in the loop for low; this signal level is often used for long-distance and optically isolated links. Connection of a current-loop device to a compliant RS 232 port requires a level translator; current-loop devices are capable of supplying voltages in excess of the withstand voltage limits of a compliant device. However, the original IBM XT serial port card implemented a 20 mA current-loop interface, which was never emulated by other suppliers of plug-compatible equipment.

Other serial interfaces similar to RS-232:

  • RS-422 (a high-speed system similar to RS-232 but with differential signalling)
  • RS-423 (a high-speed system similar to RS-422 but with unbalanced signalling)
  • RS-449 (a functional and mechanical interface that used RS-422 and RS423 signals - it never caught on like RS-232 and was withdrawn by the EIA)
  • RS-485 (a descendant of RS-422 that can be used as a bus in multidrop configurations)
  • MIL-STD-188 (a system like RS-232 but with better impedance and rise time control)

See also

asynchronous start-stop

Related Wikibooks

Please see the serial communications bookshelf for a number of helpful titles, including the RS-232 Technical Manual.

External links

References

  • Electronics Industries Association, "EIA Standard RS-232-C Interface Between Data Terminal Equipment and Data Communication Equipment Employing Serial Data Interchange", August 1969, reprinted in Telebyte Technology "Data Communication Library" Greenlawn NY, 1985, no ISBN
  • [1] "PC 97 Hardware Design Guide", 1997, Microsoft Press, Redmond Washington USA, ISBM 1572313811

es:RS-232 fr:RS-232 ja:RS-232C pl:RS-232 pt:RS-232 ru:RS-232 zh:RS-232 sv:RS-232

Navigation

  • Art and Cultures
    • Art (https://academickids.com/encyclopedia/index.php/Art)
    • Architecture (https://academickids.com/encyclopedia/index.php/Architecture)
    • Cultures (https://www.academickids.com/encyclopedia/index.php/Cultures)
    • Music (https://www.academickids.com/encyclopedia/index.php/Music)
    • Musical Instruments (http://academickids.com/encyclopedia/index.php/List_of_musical_instruments)
  • Biographies (http://www.academickids.com/encyclopedia/index.php/Biographies)
  • Clipart (http://www.academickids.com/encyclopedia/index.php/Clipart)
  • Geography (http://www.academickids.com/encyclopedia/index.php/Geography)
    • Countries of the World (http://www.academickids.com/encyclopedia/index.php/Countries)
    • Maps (http://www.academickids.com/encyclopedia/index.php/Maps)
    • Flags (http://www.academickids.com/encyclopedia/index.php/Flags)
    • Continents (http://www.academickids.com/encyclopedia/index.php/Continents)
  • History (http://www.academickids.com/encyclopedia/index.php/History)
    • Ancient Civilizations (http://www.academickids.com/encyclopedia/index.php/Ancient_Civilizations)
    • Industrial Revolution (http://www.academickids.com/encyclopedia/index.php/Industrial_Revolution)
    • Middle Ages (http://www.academickids.com/encyclopedia/index.php/Middle_Ages)
    • Prehistory (http://www.academickids.com/encyclopedia/index.php/Prehistory)
    • Renaissance (http://www.academickids.com/encyclopedia/index.php/Renaissance)
    • Timelines (http://www.academickids.com/encyclopedia/index.php/Timelines)
    • United States (http://www.academickids.com/encyclopedia/index.php/United_States)
    • Wars (http://www.academickids.com/encyclopedia/index.php/Wars)
    • World History (http://www.academickids.com/encyclopedia/index.php/History_of_the_world)
  • Human Body (http://www.academickids.com/encyclopedia/index.php/Human_Body)
  • Mathematics (http://www.academickids.com/encyclopedia/index.php/Mathematics)
  • Reference (http://www.academickids.com/encyclopedia/index.php/Reference)
  • Science (http://www.academickids.com/encyclopedia/index.php/Science)
    • Animals (http://www.academickids.com/encyclopedia/index.php/Animals)
    • Aviation (http://www.academickids.com/encyclopedia/index.php/Aviation)
    • Dinosaurs (http://www.academickids.com/encyclopedia/index.php/Dinosaurs)
    • Earth (http://www.academickids.com/encyclopedia/index.php/Earth)
    • Inventions (http://www.academickids.com/encyclopedia/index.php/Inventions)
    • Physical Science (http://www.academickids.com/encyclopedia/index.php/Physical_Science)
    • Plants (http://www.academickids.com/encyclopedia/index.php/Plants)
    • Scientists (http://www.academickids.com/encyclopedia/index.php/Scientists)
  • Social Studies (http://www.academickids.com/encyclopedia/index.php/Social_Studies)
    • Anthropology (http://www.academickids.com/encyclopedia/index.php/Anthropology)
    • Economics (http://www.academickids.com/encyclopedia/index.php/Economics)
    • Government (http://www.academickids.com/encyclopedia/index.php/Government)
    • Religion (http://www.academickids.com/encyclopedia/index.php/Religion)
    • Holidays (http://www.academickids.com/encyclopedia/index.php/Holidays)
  • Space and Astronomy
    • Solar System (http://www.academickids.com/encyclopedia/index.php/Solar_System)
    • Planets (http://www.academickids.com/encyclopedia/index.php/Planets)
  • Sports (http://www.academickids.com/encyclopedia/index.php/Sports)
  • Timelines (http://www.academickids.com/encyclopedia/index.php/Timelines)
  • Weather (http://www.academickids.com/encyclopedia/index.php/Weather)
  • US States (http://www.academickids.com/encyclopedia/index.php/US_States)

Information

  • Home Page (http://academickids.com/encyclopedia/index.php)
  • Contact Us (http://www.academickids.com/encyclopedia/index.php/Contactus)

  • Clip Art (http://classroomclipart.com)
Toolbox
Personal tools