RS-232 SERIAL COMMUNICATION OVERVIEW
RS-232 SERIAL COMMUNICATION OVERVIEW
Data is typically transmitted between two points either
asynchronously or synchronously. However, what happens to the data
between point A and point B is another discussion. This in-between
area is a cable made up of wires through which data travels. Specifications
for this cable were developed to maximize signal integrity (to limit
the possible degradation that could be caused by external noise
or ground shifts). Quatech supports three major protocols for asynchronous
and synchronous communication: RS-232, RS-422
and RS-485. Differences
between the three are highlighted in the chart below, and in the
sections which follow.
| |
RS-232 |
RS-422 |
RS-485 |
| Mode of Operation |
single ended |
differential |
differential |
| Drivers per Line |
1 |
1 |
32 |
| Receivers per Line |
1 |
10 |
32 |
| Maximum Cable Length |
50 feet |
4000 feet |
4000 feet |
| Maximum Data Rate |
20 kbps |
10 Mbps |
10 Mbps |
| Driver Output Maximum Voltage |
±25V |
-0.25 to +6V |
-7 to +12V |
| Driver Output Signal Level (loaded) |
±5V |
±2V |
±1.5V |
| Driver Output Signal Level (unloaded) |
±15V |
±5V |
±5V |
| Driver Load Impedance |
3kW
to 7kW |
100kW |
54kW |
| Max. Driver Output Current (Power on) |
n/a |
n/a |
±100mA |
| Max. Driver Output Current (Power off) |
VMAX/300W |
±100mA |
±100mA |
| Slew Rate |
30V/ms
max. |
n/a |
n/a |
| Receiver Input Voltage Range |
±15V |
-7V to +7V |
-7V to +12V |
| Receiver Input Sensitivity |
±3V |
±200mV |
±200mV |
| Receiver Input Resistance |
3kW
to 7kW |
4kW |
12kW |
The First Standard
RS-232 was introduced in 1960, and is currently the
most widely used communication protocol. It is simple, inexpensive
to implement, and though relatively slow, it is more than adequate
for most simple serial communication devices such as keyboards and
mice. RS-232 is a single-ended data transmission system, which means
that it uses a single wire for data transmission. (Since useful
communication is generally two way, a two-wire system is employed,
one to transmit and one to receive.) Signals are processed by determining
whether they are positive or negative when compared with a ground.
Because signals traveling this single wire are vulnerable to degradation,
RS-232 systems are recommended for communication over short distances
(up to 50 feet) and at relatively slow data rates (up to 20 kbps).
However, in practice, these limits can be exceeded.
DTE and DCE: Serial Communication Partners
A typical system is made up of two types of device,
data communication equipment (DCE) and data terminal equipment (DTE).
Typically DTE is defined as the communication source, and DCE is
defined as the device that provides a communication channel between
two DTE-type devices.
In order for DCE and DTE devices to communicate with
each other, two wires must be used--one for transmission and the
other for reception--and both devices must not use the same wire
for the same purpose. Should this happen, nothing would get communicated
because both devices would be talking on the same line and listening
to a line on which nothing is transmitted. To solve this problem,
DTE and DCE devices have complementary pinouts to allow terminals
and modems to be connected directly using a one-to-one cable (see
Figure below).
Situations arise in which no DCE device is needed, such as a desktop
computer communicating with a laptop. In this case, a null modem
cable or modem eliminator cable is used to connect the two DTE devices.
This cable effectively changes the wires the second device uses
for transmission and reception (see below-left) to assure that both
sides can communicate.
DTE and DCE Cable Configurations
|
Connectors: The Communication Conduit
As discussed in the asynchronous
and synchronous communication
sections, there is more to a serial transmission than simply data.
Additional information must be transmitted between both ends of
a conversation to make sure that when point A sends, point B is
listening, and vice versa. This is called handshaking. These handshaking
lines take up considerable space on a serial connector.
Connectors for RS-232 devices are always constructed
using standard assignments for the wires in a RS-232 cable in order
to maintain the DTE-DCE relationship described above. These connectors
can be modular (phone jack) or male D-shell (pins configured in
a rough "D" shape which fit into sockets on the device).
The signal assignments for the RS-232 wires follow. The descriptions
reference the standard DB-9 and DB-25 connectors used by most serial
devices, however the definitions are applicable to modular connectors
as well (though in modular connections not all of the handshaking
signals are implemented). See ESC-100M
for Quatech modular adapters for PCI that include modular connector
pinout information.
RS-232 Signal Descriptions
Abbreviations used in the following definitions of
RS-232 wire functions will be used throughout Quatech's website.
DTR: Data Terminal Ready--Used by a DTE to
signal that it is plugged in and available to begin communication.
DSR: Data Set Ready--Sister signal to DTR,
it is used by the DCE to indicate it is ready to begin communication.
CTS: Clear to Send--Used by DCE to signal it
is available to send data, and used in response to a RTS request
for data.
RTS: Request to Send--Used by a DTE to indicate
that it wants to send data. Also, in a multi-drop network, used
to turn carrier on the modem on and off.
DCD: Data Carrier Detect--Used by a DCE to
indicate to the DTE that it has received a carrier signal from the
modem and that real data is being transmitted.
RI: Ring Indicator--Used by DCE modem to tell
the DTE that the phone is ringing and that data will be forthcoming.
TxD: Transmit Data--This wire is used for sending
data.
RxD: Receive Data--This line is used for receiving
data.
GND: Signal Ground--This pin is the same for
DTE and DCE devices, and it provides the return path for both data
and hand-shake signals.
TxCLK: Transmit Signal Element Timing--Used
by DTE to provide DCE with timing information for data transfer.
RxCLK: Receiver Signal Element Timing--Used
by DCE to provide DTE with timing information for data transfer.
LLBK: Local Loopback--Used by DTE to make sure
the local transmit and receive interface is functioning properly.
RLBK: Remote Loopback--Used by DTE to make
sure a remote transmit/receive interface is functioning properly.
TEST MODE: Test Mode--Used by DCE to indicate
that it is testing itself in response to a local or remote loopback
signal from a DTE.
|