RS-422 and RS-485 Application Note International Headquarters B&B Electronics Mfg. Co. Inc. 707 Dayton Road -- P.O. Box 1040 -- Ottawa, IL 61350 USA Phone (815) 433-5100 -- General Fax (815) 433-5105 Home Page: www.bb-elec.com Customer Service e-mail: sales@bb-elec.com -- Fax (815) 433-5109 Technical Support e-mail: support@bb.elec.com -- Fax (815) 433-5104 European Headquarters B&B Electronics Ltd. Westlink Commercial Park, Oranmore, Co.
CHAPTER 5: SOFTWARE........................................................................... 33 Table of Contents INTRODUCTION ............................................................................................... 33 RS-422 SYSTEMS............................................................................................ 33 RS-485 DRIVER CONTROL.............................................................................. 33 RS-485 RECEIVER CONTROL .............................................
Chapter 1: Overview Introduction The purpose of this application note is to describe the main elements of an RS-422 and RS-485 system. This application note attempts to cover enough technical details so that the system designer will have considered all the important aspects in his data system design. Since both RS-422 and RS-485 are data transmission systems that use balanced differential signals, it is appropriate to discuss both systems in the same application note.
Balanced Line Receivers A balanced differential line receiver senses the voltage state of the transmission line across two signal input lines, A and B. It will also have a signal ground (C) that is necessary in making the proper interface connection. Figure 1.3 is a schematic symbol for a balanced differential line receiver. Figure 1.3 also shows the voltages that are important to the balanced line receiver.
EIA Standard RS-485 Data Transmission The RS-485 Standard permits a balanced transmission line to be shared in a party line or multidrop mode. As many as 32 driver/receiver pairs can share a multidrop network. Many characteristics of the drivers and receivers are the same as RS-422. The range of the common mode voltage Vcm that the driver and receiver can tolerate is expanded to +12 to -7 volts.
Figure 1.6 Figure 1.7 RS-422/485 Application Note 7 8 RS-422/485 Application Note © Copyright B&B Electronics -- Revised 2506 © Copyright B&B Electronics -- Revised 2506 B&B Electronics Mfg Co – 707 Dayton Rd - PO Box 1040 - Ottawa IL 61350 - Ph 815-433-5100 - Fax 815-433-5104 B&B Electronics Ltd – Westlink Comm.
An RS-485 network can also be connected in a four-wire mode as shown in Figure 1.7. Note that four data wires and an additional signal ground wire are used in a “four-wire” connection. In a four-wire network it is necessary that one node be a master node and all others be slaves. The network is connected so that the master node communicates to all slave nodes. All slave nodes communicate only with the master node. This network has some advantages with equipment with mixed protocol communications.
Send Data Control of an RS-485 Device Many of B&B Electronics’ RS-232 to RS-485 converters and RS-485 serial cards include special circuitry, which is triggered from the data signal to enable the RS-485 driver. Figure 1.9 is a timing diagram of the important signals used to control a converter of this type. It is important to note that the transmit data line is “disabled” at a fixed interval after the last bit, typically one character length.
Chapter 2: System Configuration Network Topologies Network configuration isn’t defined in the RS-422 or RS-485 specification. In most cases the designer can use a configuration that best fits the physical requirements of the system. Two Wire or Four Wire Systems RS-422 systems require a dedicated pair of wires for each signal, a transmit pair, a receive pair and an additional pair for each handshake/control signal used (if required).
Termination Termination is used to match impedance of a node to the impedance of the transmission line being used. When impedance are mismatched, the transmitted signal is not completely absorbed by the load and a portion is reflected back into the transmission line. If the source, transmission line and load impedance are equal these reflections are eliminated. There are disadvantages of termination as well.
System designers interested in AC termination are encouraged to read National Semiconductors Application Note 9032 for further information. Figure 2.3 illustrates both parallel and AC termination on an RS-485 two-wire node. In four-wire systems, the termination is placed across the receiver of the node. Bias Resistor Figure 2.3 Parallel and AC Termination Bias Resistor Biasing an RS-485 Network When an RS-485 network is in an idle state, all nodes are in listen (receive) mode.
Chapter 3: Selecting RS-422 and RS-485 Cabling Cable selection for RS-422 and RS-485 systems is often neglected. Attention to a few details in the selection process can prevent the costly prospect of re-pulling thousands of feet of cable. Example 2. 32 node, RS-485 network without termination Each RS-485 node has a load impedance of 12KΩ. 32 nodes in parallel give a total load of 375 Ω. In order to maintain at least 200 mV across 375Ω we need a current of 0.53 mA.
Figure 3.1 Losses in a transmission line are a combination of AC losses (skin effect), DC conductor loss, leakage, and AC losses in the dielectric. In high quality cable, the conductor losses and the dielectric losses are on the same order of magnitude. Figure 3.2 is included in this application note to point out the significant difference in performance of different cables. This chart shows Attenuation versus Frequency for three different Belden cables.
Chapter 4: Transient Protection of RS-422 and RS-485 Systems 1.2/50 uSecond 1 0.9 The first step towards protecting an RS-422 or RS-485 system from transients is understanding the nature of the energy we are guarding against. Transient energy may come from several sources, most typically environmental conditions or induced by switching heavy inductive loads. 0.8 0.7 V(t) / Vp 0.6 0.5 What does a surge look like? 0.
100kHz Ring Wave Ground ≠ Ground 1 Realizing that transient energy can be high frequency in nature leads to some disturbing observations. At frequencies of this magnitude, it is difficult to make a low impedance electrical connection between two points due to the inductance of the path between them. Whether that path is several feet of cable or thousands of feet of earth between grounding systems, during a transient event there can be hundreds or thousands of volts potential between different “grounds”.
Isolation Devices Vcc Port Device Optical isolation can be implemented in a number of ways. If a conversion from RS-232 to RS-422 or RS-485 is being made, optically isolated converters are available. Optically isolated ISA bus serial cards can replace existing ports in PC systems. For systems with existing RS-422 or RS-485 ports, an optically isolated repeater can be installed. Examples of each of these type devices can be found in the B&B Electronics Data Communications catalog.
Connecting Signal Grounds Device Vcc Since a local ground connection is required at each node implementing shunt type protection, the consequences of connecting remote grounds together must be considered. During transient events a high voltage potential may exist between the remote grounds. Only the impedance in the wire connecting the grounds limits the current that results from this voltage potential.
Special Consideration for Fault Conditions Data systems that could be exposed to short circuits to power conductors require an extra measure of protection. In these cases its recommended to add a fuse type device in addition to shunting type suppression, as shown in Figure 4.9. When a short circuit occurs, the shunt suppression will begin conducting, but shunting by itself cannot withstand the steady state currents of this type of surge.
Chapter 5: Software RS-485 Receiver Control Introduction RS-422 and RS-485 are hardware specifications. Software protocol is not discussed in either specification. It is up to the system designer to define a protocol suitable for their system. This chapter we will not attempt to define a protocol standard, but will explain some of the issues that should be considered by the system designer, whether writing or purchasing software. RS-422 Systems The RS-485 receiver also has an enable signal.
Chapter 6: Selecting RS-485 Devices Multi-Master RS-485 Systems Each node in a multi-master type RS-485 system can initiate its own transmission creating the potential for data collisions. This type system requires the designer to implement a more sophisticated method of error detection, including methods such as line contention detection, acknowledgement of transmissions and a system for resending corrupted data.
Chapter 7: Sources of Further Information Appendix A: EIA Specification Summary EIA Standards and Publications can be purchased from: GLOBAL ENGINEERING DOCUMENTS 7730 Carondelet Avenue Clayton, MO 63105 Phone: (800) 854-7179 FAX: (314) 726-6418 EIA RS-422 Specification Summary Parameter Driver Output Voltage Open Circuit Driver Output Voltage Loaded Driver Output Resistance Driver Output Short-Circuit Current Driver Output Rise Time GLOBAL ENGINEERING DOCUMENTS 15 Inverness Way East Englewood, CO 80112
Appendix B: EIA Standard RS-423 Data Transmission RS-423 (EIA-423) is another standard used in point to point communications. RS-423 data transmission uses an unbalanced line driver that connects to an RS-422 type balanced line receiver as shown in Figure B.1. The RS-423 line driver is unique to this system. It produces voltage similar to RS-232 but has a slew rate control input that is used to limit rise times and cross talk on the data lines.