Back to


CAN bus Edit

CAN bus

RS485 notes Edit

*  Signal and earth ground
* Round robin protocol for RS-485 - AtmelMicro
* RS422 uses two TwistedPair for full-duplex communication.
* One RS485 implements bidirectional communication in half-duplex mode on a single TwistedPair.
* RS485 specifies same voltage levels as RS422, namely TTL 5v.
* It is not a protocol but a hardware signaling standard. Any protocol can be implemented over it.
* Inverting connects to inverting and Non to non in all cases -
* Common mode max is +-7v between R+ and R-
*  Uses RS485
* ModBus
* DmxProtocol

RS485 and RS232 standard Edit

RS485 allows connecting of computers and terminals via hard conductors. RS-232 was designed to connect terminals to modems. It thus specifies several control signal lines that indicate modem and terminal status. Control lines aren't required with RS-422. Half duplex means that only one device at a time on the network can transmit. Full duplex is when both (all) devices can transmit simultaneously. Depending on what RS-485 interface you are using you can have half duplex or full duplex RS-485. For half duplex you have a single twisted pair that is connected to the transmitter and to the receiver of each device. The transmitters of the devices that are not transmitting must be in high impedance. For full duplex you have two twisted pairs. The first is connected to the transmitter of the master and to the receivers of the slaves. The second is connected to the receiver of the master and to the transmitters of the slaves. But since you can only have one device transmitting at a given time on the same twisted pair, even in full duplex RS-485, the master must initiate the transfer by selecting a slave. Then both the master and the slave can transmit in full duplex (simultaneously). This is purely a problem of protocol, i.e. software. RS-485 full duplex interface chips allow two devices to transmit simultaneously. You must arbitrate when you have more than one slave.

Control pins Edit

The MAX481 or 75176 has two control pins(RE/OE) that enable reception and transmission. When the pins are tied together the chip is in receive mode when the control voltage is TTL low. It is in send mode when TTL high. This allows reversal of signal direction under program control in half-duplex mode, which allows for master slave communication. With the master RE/OE pins high all the slaves RE/OE pins must be low placing the slaves in receive mode. The master sends an unique address packet talking to the slave. The slave waits 100us before sending it's data to the master. Upto 32 slaves can talk to the master in this way.

he 485 spec defines an electrical bus consisting of 2 wires and thats it. It talks about what the loads of each transceiver must be and the amount of ground difference the bus can take without causing an "off" transceiver to turn on unexpectantly. The fun thing was that they never tried to specify connectors or anything handly like that, so the spec was widely excepted and generally different from one machine to the next (though screw terminals, I suppose became the defacto standard).

The 4-wire 485 is two 485 buses where one is turned into a unidirectional transmitter bus from master to slaves. The master is generally always transmitting and the slave always receives. The other is receiver bus and is multidrop in the 485 sense (except the master usually doesn't talk in this scenario). This is a scenario I actually saw in the RS-422 spec however true RS-422 didn't have the same electrical spec as 485 (couldn't handle as many drops and had a different differential gound reference I believe, it has been a while since I looked at the spec). The benefit here is that the master should always be able to talk to the slaves, which can be handy if the return bus has a unit that won't be quiet.

Though the "RTS" has become the signal line of choice for controling this, I think your instructor is doing you a disservice by specifying it as some kind of 485 signal. It is never mentioned in the spec, just something that was handy when they started to marry these things to Serial controller chips. A lot of 485 is connected to embedded processors, that generally don't have RTS lines, it is just another digital io pin.

Determine the logic condition Edit

The logic condition is determined by the difference in the voltage levels on the conductor pair. Pin.6 (A) is the non-inverting and (B)pin.7 the inverting input. Any noise will appear on both lines at A&B and will be cancelled out. At the transmitter one pair conductor is at +5v, the other at ground. Reverse the logic by reversing the voltage levels on a pair. So for a logic 1 place +5v on (A)-IC2 and 0 on (B). For a logic 0 place +5v on (B) and 0v on (A)-IC2.

Transmitting from Master to Slave Edit

Connnect the Tx of the AtmelMicro to the DI input of the master MAX481(IC2). On DI receiving +5v results in (A) high and (B) low. The slave on the other end of the line receives (A)master on its (A)-IC3 input and its (B)-IC3 slave connects to (B)master. When RTS is asserted positive, R1in - IC1(MAX2320 is high and R1Out is low, placing the RS485 MAX481 in receive mode. With RTS low the MAX481 is in transmit mode.

Biasing resistors Edit

Use two 760ohm biasing resistors (R2 AND R3) on the line to Vcc and Gnd each. This is to keep a small 200mv differential over the terminating resistor. When the RS-485 network is in an idle state, no active drivers are driving the line. The transmission line reaches a meta-stable state and the logic level is not known at this point. It becomes important to have biasing resistors to passively pull the line to a known state. Bias resistors are nothing more than a pull-up (typically to 5 volts) and a pull-down resistor (to ground) on the data A line.(p.29

Common ground conductor Edit

Don't use a common ground conductor it will only pick up noise. Use only a single TwistedPair wire for RS485. (This depends though if you use transient suppressors you must have common ground). Which is bad, because the common mode voltage on RS485 may not exceed 7V. Always use a ground connection too.

> What I was thinking of is to run Cat5 as close to each machine as > possible and connect it to a plain old surface mount modular RJ11 > telephone box (you know, like what your phone cord plugs into). Then I > could use a standard RJ11 telephone cable (like what connects your > modem to the phone line) to hook the machine up to the network. (The > machine would also have a modular RJ11 telephone box which would be > connected to the RS485 transceiver of the electronics that I'll > design).

Not a problem if it's short. And definitely not at 9600 baud. If it's a noisy environment you might miss the shield though.... Always use slew rate limited parts when possible! We use slew rate limited, failsafe, with short circuit protection drivers and everything has been goin along great.

post 119 says that the correct term is common-mode reference

comp.home.automation Edit

* Rs485IsBidrectional 
* Rs485Post104
* LastCharacter485
* CharlesFalconeSerialRoutines
* MatchCableImpedance
* EarthLoopProblem485

One shot triggers RS485 Edit

* OneShotTriggersDtr485

Terminating resistors Edit

There must only be two terminating resistors(R1 and R4). One at each end of the line. Not one for each RS485 device. Upto 32 RS485 devices connects in parallel on a single TwistedPair. The transmitter has a low source impedence. The line should be terminated with a low 120ohms resistor. Noise induced in the line affects both conductors so that little or no change in difference appears at the receiver.

Jan Axelson Edit

* file microsys_art_RS485.pdf
*   Jan Axelson

{{{ J. Axelson, Serial Port Complete: Programming and Circuits for RS-232 and RS-485 Links and Networks, Lakeview Research, Madison, WI, 1998. }}} Edit


RS422 Edit

RS422 using two TwistedPair allows for full-duplex communication.

two or three wire Edit


RS485 is a 2 wire network if done right. Profibus is a typical example of a true 2 wire RS485 system. The secret to trouble free RS485 is to use isolated power supplies to run the RS485 transeiver. Low cost, low current, high speed non optical isolators are now available from Analog Devices (the ADUM1300 series) and simple to implement power supply isolators are also available from Maxim (MAX253 & MAX845). Combining these parts with any standard RS485 transeiver builds you a fully isolated interface that truely needs only 2 wires. You must provide biasing resistors with this setup to center the RS485 signals within the isolated interface common mode range. A sample of an isolated interface can be found in the booklet “The rapid way to Profibus” or I can send you as sample circuit if you are interested.

Links Edit

* ConfiguringAlarmSystem
* CompHomeAutomation
* Round robin protocol for RS-485 - AtmelMicro
* RS232 code for 8051
* Python RS232 serial code
*  AVR schematic of RS485 connected to Rx/Tx pins
*  RS485 software 
*  RS232 to RS485. RS485 to Ethernet converter. 
* EDN desing feature 1996
* CircuitCellar

More links Edit

Telcos solve surge problem Edit

Image Edit


See ["RS-422"]

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.