RE: [AVR-Chat] When boyscouts say one for all, all for one
2007-02-28 by Tim Mitchell
magzky02 wrote: > hello guys, > > i have a system that has 1 master microcontroller that communicates to > 18 slave microcontrollers. I am going to use a USART in UART mode. > Since the master is using only one UART, there are control lines so > that the communication b/n slave and master is one at time to avoid > corruption. My question is that is this method reliable? When one > slave controller transmit (toggling the lines high and low), hows > does other slave controller affect the data? will they hold the line > high? Any idea? > > consulted mr google and seems rs485 is one solution. > RS485 is definitely a good way, it is designed for this sort of thing. You use a chip such as SN75176 to connect the units to the data line. When the inactive slaves are switched to "receive" they do not affect the data line. You would not normally use extra control lines. You would give each slave some sort of unique address to identify which one you want to talk to. When the master transmits a command to the slave using its unique address, that slave would then have a fixed time slot to transmit back to the master. -- Tim Mitchell tim@sabretechnology.co.uk http://www.sabretechnology.co.uk Sabre Technology (Hull) Ltd, 3a Newlands Science Park, Hull HU6 7TQ t:01482 801003 f:01482 801078