Designing for Manufacturing
Show MenuHide Menu

RS485 Termination & Bias Resistors

November 21, 2012

I was looking at interconnecting several PCBs with some low speed data (for model railway control) and was looking for a low cost easy to program solution.

CANBUS is all the rage, but the chips which interface the PIC and CANBUS are about £2 each.  That, coupled with the complexity of the software required to drive them put me off.

The obvious choice is RS485, with interface chips (MAX485, LTC485, ect) costing  $0.25 to connect between the USART on the micro and the RS485 bus itself.  These can be dedicated USART pins (RC6 and RC7 on most PICs) or you can use software USART with almost any pins.

I program in Mikrobasic which has built in routines for RS485 comms, able to send 1, 2 or 3 bytes at a time from a master to any slave on the bus.  They can then reply back to the master.

RS485 is the definition of the physical interface, although it avoids definition of the connector types (I have chosen screw terminals to minimise cost).

Whenever a master or slave sends a message, it travels down the line, and will reflect off each end.  To eliminate this you can choose to terminate both ends of the line (you terminate the sending end so the signals sent by the slaves are also absorbed).  The line ideally has a characteristic impedance os 120 ohms, to 120 ohm resistors are placed at each end.  The disadvantage for me is that my users need to know about these intracies, and really I want to make things as easy as possible for them.  It also means you need to add biasing and power consimption is increased.

Luckily, if you choose low data rates, you can avoid the need for the termination resistors altogether.  The signal is sampled half way through the symbol period, so if this is a long enough period after the start of the symbol for relections to have died out sufficiently, then the terminations resistors are unnecessary.

After reading around the subject, I would make my board capable of being connected as follows:

This allows for 120 ohm termination at each end of the line, and also for a pair of 560R biasing resistors at the bus master.  The bus wiring is ideally twisted pair, with a screen, which is connected to the ground at each device on the bus via a 100R 0.5W resistor.

I recommend the excellent article by Jane Alexon at http://www.lvr.com/rs-485_circuits.htm which covers RS485 concisely (although note the first image in the article was incorrect when I last looked).

Leave a Reply

Your email address will not be published. Required fields are marked *