New DOCX Document (4)

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 5

How do you choose between

RS232, RS485, and RS422 for


your hardware design project?
If you are working on a hardware design project that involves serial
communication, you might wonder how to choose between RS232,
RS485, and RS422 protocols. These are three common standards
that define the electrical characteristics, wiring, and signaling of
serial data transmission. In this article, you will learn the main
differences, advantages, and disadvantages of each protocol, and
some tips to help you decide which one suits your project best.

RS232: The Simplest and Oldest


Protocol
RS232 stands for Recommended Standard 232, and it was first
introduced in 1960. It is a point-to-point protocol, which means that
it connects one transmitter and one receiver using a single pair of
wires. It is also a full-duplex protocol, which means that data can
flow in both directions simultaneously. RS232 is easy to implement
and widely supported by many devices and software applications.
However, it also has some limitations, such as low speed (up to 20
kbps), short distance (up to 15 meters), and susceptibility to noise
and interference.

RS485: The Multi-Point and Robust


Protocol
RS485 stands for Recommended Standard 485, and it was
developed in 1983. It is a multi-point protocol, which means that it
can connect up to 32 transmitters and 32 receivers using a single
pair of wires. It is also a half-duplex protocol, which means that data
can flow in one direction at a time, and the devices need to take
turns to transmit and receive. RS485 is fast (up to 10 Mbps), long-
distance (up to 1200 meters), and noise-resistant, making it suitable
for industrial and network applications. However, it also requires
more complex wiring, termination, and addressing, and it cannot
support full-duplex communication.
RS422: The Compromise Between RS232
and RS485
RS422 stands for Recommended Standard 422, and it was derived
from RS485 in 1978. It is a point-to-multipoint protocol, which
means that it can connect one transmitter and up to 10 receivers
using a single pair of wires. It is also a full-duplex protocol, which
means that data can flow in both directions simultaneously, but it
requires an additional pair of wires for the reverse direction. RS422
is faster (up to 10 Mbps) and longer-distance (up to 1200 meters)
than RS232, and less noisy than RS485. However, it also consumes
more power, requires more wires, and cannot support multi-point
communication.

How to Choose the Right Protocol for


Your Project
When selecting a protocol for your project, there is no definitive
answer as it depends on various factors, such as data rate, distance,
noise level, number of devices, and budget. Generally speaking,
RS232 is a simple and inexpensive solution for connecting two
devices over a short distance and low speed. RS485 is a good choice
for connecting multiple devices over a long distance and high speed
with some complexity and cost. RS422 should be considered if you
need to connect one device to multiple devices over a long distance
and high speed with full-duplex communication. It is important to
research, test, and compare the different protocols to ensure
compatibility, reliability, and security.

RS-232 AND RS-485


DIFFERENCES
RS-232 and RS-485 are standards for serial interfaces
that each specify the transmission media and a
defined set of logic levels, data rates and timings.
These are some of the oldest serial interfaces around,
yet they are still very widely used in control and
measurement equipment, mainly due to their
simplicity and low cost.

RS-232
RS-232 is the simplest of the two interfaces. It is used
to connect two devices as illustrated below:

That is, the transmitter of Device 1 is connected to the


receiver of Device 2 and vice versa. Both lines are
single-ended with a ground reference. The standard
specifies a voltage between -3 and -25 V as a logic 1
and a voltage between +3 and +25 V as a logic 0. The
cable used to connect Device 1 and Device 2 can be
made up of either parallel wires or a twisted pair and
should generally not exceed 15 meters.
Most serial devices use a Universal Asynchronous
Receiver Transmitter (UART) integrated circuits to
implement a communication protocol that transmits
portions of data (typically 8 bits) along with a defined
set of start-bits, stop-bits, and parity-bits at a specified
data rate. The transmitted data is often ASCII
characters. Data rates typically range from 4800 to
115.200 baud.

Advantages

 Very widely used


 Low complexity
 Supports full duplex

Disadvantages

 Only supports communication between two devices


 Only works over short distances
 Relatively susceptible to noise

RS-485
While RS-485 and RS-232 have a lot in common
regarding the data format, they differ on a very
significant parameter: Where RS-232 specifies single-
ended connections referenced to ground, RS-485
specifies differential signaling on two lines, called A
and B. Up to 32 devices can be connected via the
same RS-485 bus, though only one device can “talk”
at any given time (half-duplex).


 Share

RS-232 AND RS-485


DIFFERENCES

A voltage of -200 mV is specified as a logic 1, while


+200 mV is specified as a logic 0. In its nature, the
differential format provides common-mode noise
cancellation. The differential format along with the
lower voltage levels also enable higher data rates and
much longer cable lengths than RS-232. Depending
on the data rates, cables can be up to 1200 meters
long. According to the RS-485 standard, the cables
must be twisted pairs.

Advantages

 Supports several devices on the same bus (multi-


drop)
 Less susceptible to noise than RS-232
 Works over longer distances
 Supports faster transfer speeds than RS-232

Disadvantages

 Not as widely used as RS-232


 Requires termination resistors
 Only supports half-duplex

Generally, RS-232 is the simpler solution for


connecting two devices over short distances. RS-485,
while allowing connection of several devices on the
same bus over greater distances, does require
termination resistors. Also, many PCs or PLCs come
with one or more RS-232 ports as standard, while RS-
485 ports are often sold separately.

You might also like