RS-485 - larmhantering, trygghetslarm och överordnat system

RS-485

RS-485

RS 485, EIA 485 or ISO 8482, is a standardized technology for serial data communications. RS485 is both simple to use and cheap, as well as very robust. It has come to be the most widely used bus technology for alarm systems.

RS 485 only specifies how transmitters and receivers communicate at an electric level to transfer bytes (characters), not the meaning of those characters. There are numerous protocols that use RS 485 for data transfer that define how information is sent across an RS 485 bus.

The technology supports cable length of over 1200 metres and speeds up to 35 Mbit/s, although not at the same time. There's a trade-off between speed and cable length, at 35 Mbit/s the maximum length is only 10 metres. All devices on the bus must use the same bitrate. Up to 32 devices can be connected per segment.

Bitrate Max cable length [m]
9600 bit/s 1200
19200 bit/s 1200
200 kbit/s 1000
500 kbit/s 500
1,5 Mbit/s 200
3 Mbit/s 100
6 Mbit/s 100
12 Mbit/s 100
35 Mbit/s 10

The values above are valid for twisted pair cable with a capacitance < 30 pF, impedance between 135 and 165 ohm and a loop resistance of 110 ohm/km.

Cable

An RS 485 bus consists of two wires - A and B. Commonly, one pair of wires is also used for power supply, thus you often need two pairs of wires for a RS 485 device. The cable you use needs to have twisted pairs, as straight cables risk to make the system more suceptible to noice and interference, as well as increase the risk of interfering with other systems.

Cables used for computer networking, like CAT-5 or CAT-6, is well suited for RS 485 buses. These types of cable have 4 pairs. It might be good idea to use one of the extra pairs for doubling up the power supply wires, as this reduces the voltage drop.

Colour Signal
Blue/White RS-485 A
Blue RS-485 B
Orange/White Power +
Orange Power +
Green/White Ground -
Green Ground -

Please note that A and B should never be doubled in this fashion. A and B should always use a single pair.

Network topology

All devices are connected in a bus structure (line). Up to 32 devices can be connected to the same segment. To the start and end of each segment, a bus termination should be connected.anslutas. Termination prevents signal reflections from the cable ends.

The termination usually consists of a 120 ohm resistor conencted between A and B. At some point in the system, you should connect a pull up and pull down resistor to keep the signal lines at known levels while all devices are idle (not transmitting).

Busstopologi

Termination and pull up/down 

If you run into problems with the bus not working when a 120 ohm termination resistor is connected, while it seems to work without any termination at all, this is probably due to missing pull up/down resistors in the RS 485 chips.  Try adding such pull up/down resistors as shown in the picture below. The pull up resistor has about twice the resistance of the pull down resistor to keep A and B at about 3 volts. 

 Bussterminering

In BXO Vidar, this connection already exists, and to enable the termination circuitry all you need to do is connect the two jumpers on the back of the PCB.