Difference Between RS232, RS422, And RS485 Converters

download Difference Between RS232, RS422, And RS485 Converters

of 9

Transcript of Difference Between RS232, RS422, And RS485 Converters

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    1/9

    What is the Difference BetweenRS232, RS422, and RS485

    Converters?While to an electronic data communications engineer or specialist, the differencebetween RS232, RS422 and RS485 is clear as day, to the rest of us they are justsome ancient industry standards that have probably all been replaced by USBanyway. Or at least you can use a converter to deal with them. The latter is true, butthe former really isn't: those standards are very much alive and continue to be usedin a wide variety of applications. But let's take a look at the backgrounds of thosestandards.

    RS-232, a standard of the Electronics Industries Association (EIA), has beenaround for over four decades. It goes back to the days where remote Teletypemachines were connected to mainframes via modems. Communication betweenthose DTE (Data Terminal Equipment) machines and DCE (Data Circuit-terminating Equipment) happened sequentially, one bit at a time. It was all slowand quite mechanical, with different voltage levels compared to ground,representing binary system ones and zeros. Serial communication is quite simple,but early on manufacturers experimented with various control signals, pin layouts

    and proprietary methods. With RS232, the EIA established a standard thatminimized incompatibilities and made life a lot easier for information technologydepartments and anyone else involved with data communication.

    RS232 turned out to be a very enduring standard that remained a primary means ofdata communication until the mid-1990s, and it is still being used today. There are,however, some inherent shortcomings and limitations to RS232, primarily in theareas of speed, reliability and flow control. The RS422 standard addresses some ofthose issues with two sets of twisted pairs that carry negative and positive voltages.The RS-422 standard offers speeds up to 10 megabits per second and themaximum connection distance is 4,000 feet. In addition, since it uses two twistedpairs, with RS-422 you can communicate in both directions simultaneously.However, RS-422 also has an important limitation: it is still a point-to-point protocoland therefore unsuitable for many multi-drop applications. This is where RS-485

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    2/9

    comes in.

    RS-485 works very much like RS422 in terms of speed and distance, also usingtwisted pairs and voltage differentials for serial binary data communication.

    However, unlike with RS-422, with RS485 devices are addressable (like inEthernet) and therefore can communicate with multiple nodes (up to 32). RS-485 istherefore suitable for a variety of master/slave architecture connections andnetworks. With more addressable devices and each device being able tocommunicate bidirectionally, line termination becomes an issue and requiresspecial consideration.

    What it all boils down to is that these older serial communication standards are stillbeing used. USB may have largely replaced RS232 serial connectivity in consumer

    products, but in many industrial and commercial systems, serial datacommunication remains very much alive. Which means that anyone dealing withserial communication products and systems will need not only an understanding ofthe standards and principles behind the standards, but also a tool chest of serialdata converter products. That includes RS-232, RS-422 and RS-485, but also TTLand fiber optics converters and adapters.

    What is TTL and How Does it Relate to

    RS232?Most people who are at least somewhat technically inclined know what USB,Ethernet and RS232 are and perhaps even how they work. A good percentage ofthem also know of RS422 and RS485 and how those standards relate to RS232.Many have used converters when dealing with those serial standards. What'samazing is that comparatively few know what TTL stands for, and what is meant byTTL communication and TTL devices.

    To be honest, unless you're an electrical engineer or hobbyist, information on TTLis not that easy to come by. If you look it up you actually find two definitions for TTL,both referring to data communication. One is "Time to Live" and refers to a datafield in the Internet Protocol that indicates how many more hops a data packet willtravel on the Internet before it is returned or discarded. A second one, and the onewe're interested in, is "Transistor-Transistor Logic" but even that requires extra

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    3/9

    explanation.

    Transistor-Transistor Logic, or TTL, refers to a way of constructing digital circuits. Itwas invented in the early 1960s when first Sylvania and then Texas Instruments

    created TTL-based integrated circuits. In TTL circuits, there are two transistorsresponsible for driving chip output, one of them generating the logical zero and theother the logical one. With TTL, a logical "zero" is defined as ground (or usually 0 to0.4 Volts), and a logic "one" as plus 5 Volt. That made a lot of sense since it issimple and microcontrollers are usually run on a single supply voltage.

    RS232, on the other hand, defines a logic "zero" as larger than plus three Volts anda logic "one" as less than minus 3 Volt. Voltages around zero, which is usuallyground, are not considered a signal at all. Why use positive and negative voltages

    when circuits are natively generating either a voltage or no voltage? Becausesignal degradation and interference are much more likely to render a TTL signalunusable than a RS-232 signal where a "one" is very clearly negative and a "zero"very clearly positive. This means that TTL signals are generally used for fastcommunication within a device whereas RS232 signals are used for slowerexternal connections over longer distances.

    Do note that there is a difference between actual TTL circuits, and using the term"TTL" to simply refer to the voltage levels used for communication. "TTL"

    communication can happen without any actual TTL circuits or devices present.

    Anyway, you can see the difference between TTL and RS232 now: one is based onsignals generated by a certain type of integrated circuit, the other refers to signalsthat are specifically defined for reliable data communication.

    Equally clear should be the need for a converter when you're dealing with bothstandards. Voltages need to be properly "translated" between the standards. Moreprecisely, signals ranging from ground to 5 Volts must be translated into signals

    that can be up to plus or minus 10 Volts. That requires additional power sourcesand voltage inverter circuitry. Modern converters usually don't need an externalpower supply as they are powered by the RS232 data lines themselves. Also notethat serial to TTL adapters are available between RS232 and TTL as well asRS485 to TTL, and that TTL devices can be 3.3 Volt or 5 Volt, so make sure you getthe proper converter.

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    4/9

    RS232 / RS422 / RS485 DB9 & DB25 serialport pinouts and loopback wiring

    DE-9 (DB9) Connector The DE-9 connector is the most common serial connector. This connector is foundon National Instruments one and two port serial interfaces.

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    5/9

    Figure 1: Pinout diagram for DE-9 Connector

    To perform a loopback test with no hardware flow control, you will need to connectpins 2 and 3 for RS-232 and pins 4 to 8 and 5 to 9 for RS-422/485. Theseconnections can be seen in red below (figure 2 for RS-232 and figure 3 for

    RS-422/485).

    When using hardware flow control, you will need to connect pins 4 to 6 and 7 to 8for RS-232. Pins 7 and 8 are used for RTS/CTS hardware flow control where pins4 and 6 are used for DTR/DSR hardware flow control. For RS-422/485, you willneed to connect pins 2 to 3 and 6 to 7. Both of these connections are required forRTS/CTS hardware flow control since RS-422/485 have differential connections.These connections can be seen in blue below (figure 2 for RS-232 and figure 3 forRS-422/485).

    Figure 2: RS-232 female DE-9 plug with connections required for loopback test

    Figure 3: RS-422/485 female DE-9 plug with connections required for loopback test

    DB-25 Connector This connector is not as common as the DE-9 connector. This connector can stillbe used to perform a loopback test with a method similar to the one used for theDE-9 connector.

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    6/9

    Figure 4: Pinout diagram for DB-25 Connector

    Most of the pins on DB-25 connectors are not connected since only nine pins areused for RS-232, RS-422, and RS-485 communication.

    To perform a loopback test with no hardware flow control with a DB-25 connector,connect pins 2 to 3 for RS-232. For RS-422/485 connect pins 5 to 20 and 7 to 22.The required connections can be seen in red on figures 5 and 6.

    For hardware flow control using RS-232, pins 4 and 5 must be connected along

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    7/9

    with pins 6 and 20. When using RS-422/485, pin 5 must connect to pin 20 and pin7 must connect to pin 22. This will allow the loopback test to use the proper flowcontrol lines. These connections can be seen in blue on figures 5 and 6.

    Figure 5: RS-232 female DB-25 plug with connections required for loopback test

    Figure 6: RS-422/485 female DB-25 plug with connections required for loopbacktest

    10P10C (RJ50) Connector This connector is most commonly found on National Instruments 4 port serialinterfaces. The National Instrument 4 port serial interfaces come with 4 10P10C toDE-9 male converter cables.

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    8/9

    Figure 7: Pinout diagram for RJ50 Connector

    It is not recommended to use the 10P10C connector by itself to perform a loopbacktest due to the small separation between pins. Using a 10P10C to DE-9 connector(Part Number 192190-01), a looback test can be performed using the methodsdescribed above.

  • 8/13/2019 Difference Between RS232, RS422, And RS485 Converters

    9/9