RS-485 interface for connecting multiple devices

RS-485 is updated version of RS-422 interface. It is designed to communicate between multiple devices connected to single data line. Standard allow connecting 32 transceivers to data line. This is achieved by using tri-stable drivers that are separate programmable. This allows only one device work at a given time.

rs485.gif

Resistors used in circuit are so called termination resistors for matching impedances of transmitter and receiver to avoid reflections. Matching resistor depends on cable used, but is 120Ohm.

Usually RS485 chips have two control inputs Data Enable(DE) and Receiver Enable(RE):

RS485_chip.PNG

On the IC you see that DE active is high level and RE is low level. This allows connecting control line to single MCU pin. This assures that node won’t be receiving while it is transmitting:

RS485_Enable_MCU.PNG

In many cases CAT-5 cable is used with impedance of 100Ohm and terminations of 120Ohm resistors at both ends of transmitter and receiver. CAT-5 cable has already twisted pairs and it is cheap enough to use for many applications.

Blogsphere: TechnoratiFeedsterBloglines
Bookmark: Del.icio.usSpurlFurlSimpyBlinkDigg
RSS feed for comments on this post
 |  TrackBack URI for this post

New on WinAVR Tutorial
Running TX433 and RX433 RF modules with AVR microcontrollers,
Sometimes in embedded design you may want to go wireless. Might be you will want to log various readi …
Programming AVR ADC module with WinAVR,
Most of AVR microcontrollers have Analog to Digital Converter (ADC) integrated in to chip. Such solut …
New on WinARM Tutorial
What are differences between WinARM and WinAVR,
Everyone who is working with AVR microcontrollers knows this powerful tool – WinAVR (http://win …
LPC2000 watchdog timer,
As in all microcontrollers watchdog timers purpose isto reset microcontroller after reasonable amount …

2 Responses to “RS-485 interface for connecting multiple devices”

  1. Mark Says:

    Thanks for this site and this article.

    It answered a couple of questions for me

    I am building this :

    http://www.pcdimmer.de

    I know the 2313 chip is obsolete but i have a couple dozen already.

    I would like to know if this limit of 32 nodes is theoretical or physical?

    I would plan on chaining these boards and when a board wants to communicate, it will pull the DE/TE line low or high, and that each node would have to check if the line is in the proper state before it tries to send. Each node is addressable so they would ignore data destined for either the master or any other slave.

    I would like to talk more about this to you if you have time.

    Thanks again for the good information.
    Mark

  2. scienceprog Says:

    “When using the default RS485 receivers with an input resistance of 12 kΩ it is possible to connect 32 devices to the network. Currently available high-resistance RS485 inputs allow this number to be expanded to 256.”
    So all depends on receiver input resistance.
    About constructive discussions - I hadn’t chance yet to try RS485 interface, so this is still theoretical subject to me.

Leave a Reply