Difference between revisions of "RS485 Termination"
Line 31: | Line 31: | ||
HOWEVER: 3rd party devices may not do this, or may even disturb this biasing by low impedance or reverse polarity biasing. | HOWEVER: 3rd party devices may not do this, or may even disturb this biasing by low impedance or reverse polarity biasing. | ||
The problem can be clearly deteced if such a device is connected to the Barionet- the RS-485 indicator LED will stay "on" because an active transmission is detected. If you want to use such a device with Barix equipment, you need to provide (stronger) bias outside of the Barix devices, by using 2 resistors to pull up and pull down the two bus lines correctly. | The problem can be clearly deteced if such a device is connected to the Barionet- the RS-485 indicator LED will stay "on" because an active transmission is detected. If you want to use such a device with Barix equipment, you need to provide (stronger) bias outside of the Barix devices, by using 2 resistors to pull up and pull down the two bus lines correctly. | ||
(NOTE: Often times a single pull-down resistor will do the trick. We typically use a 1000 ohm resistor between the RS485- and RS485 shield on J7 of the BarioNet when using it with our RS485 i/o devices. - Adam) | (NOTE: Often times a single pull-down resistor will do the trick. We typically use a 1000 ohm resistor between the RS485- and RS485 shield on J7 of the BarioNet when using it with our RS485 i/o devices. - Adam) |
Revision as of 16:48, 5 January 2009
RS-485 line termination and "pull up/pull down"
Several Barix products provide an RS-485 interface.
General Comments
An RS-485 (sometimes also written RS485) interface is generally bidirectional, a "bus" structure (which is different to RS-422, which is point-to-point).
To work as a bidirectional device, the transmitter generally must be switched off and only drive the line if the device has something to say.
The RS-485 signal uses 2 wires, which are driven alternatively (inverse). the receivers look at the difference, not the absolute voltage value, of the two wires - a difference of higher than 0.3V (300mV) is accepted as a valid signal, absolute values below 0.3V are considered "undefined" and may result in either high or low reading.
In many applications, a "ground reference" line is available in addition to the 2 data lines (typically connected to the device ground through a 100 Ohm resistor), but this is not absolutely necessary.
You can find a lot of information about the RS-485 technology in general on the internet, for example in Wikipedia.
Line Termination
For high speed applications, the bus should be terminated to avoid electrical reflections which can disturb the signal. Line termination must only be done at both ends of the bus - not anywhere at a device in the middle. Our experience is that line termination is "optional", and not required in many installations, if slower speeds (such as 19200 baud in case of Modbus/RTU) are used. Barix devices currently do *not* provide onboard termination resistors.
Line Bias
Line bias is critical in RS-485 applications. At times where no transmitter is active, the bus should be forced to the "idle" state. This is typically done at the master side.
The Barionet is not necessarily a master - it is a universal device which can be used as master or slave on an RS-485 bus infrastructure. A common technique to get to reasonable line bias, implemented in the Barix devices, is to use "weak" (10kOhm or similar) pullups and pulldowns in each device to provide the line bias.
Barix devices all do this - if no transmitter is active, the bus is pulled via these resistors (in every device !) to the idle state so all devices see the correct difference no the bus.
HOWEVER: 3rd party devices may not do this, or may even disturb this biasing by low impedance or reverse polarity biasing.
The problem can be clearly deteced if such a device is connected to the Barionet- the RS-485 indicator LED will stay "on" because an active transmission is detected. If you want to use such a device with Barix equipment, you need to provide (stronger) bias outside of the Barix devices, by using 2 resistors to pull up and pull down the two bus lines correctly.
(NOTE: Often times a single pull-down resistor will do the trick. We typically use a 1000 ohm resistor between the RS485- and RS485 shield on J7 of the BarioNet when using it with our RS485 i/o devices. - Adam)