Society of Robots - Robot Forum
Electronics => Electronics => Topic started by: Joker94 on December 29, 2009, 09:50:38 PM
-
With Uart is it the same as I2C in the way that you can use the same 2 pins for multiple devices.
Or do you need different UART lines for each device.
I hope i have made my point clear.
Joker94
-
different UART for each device
mega168/mega8 only has 1 uart available, so you can communicate with only one other device
-
Although, if you only had to receive from a certain device you could only use rx and gnd.
Same goes from only having to transmit...
-
Great
so i could potentially have 2
thanks
Joker94
-
there are many devices i've encountered that have a daisy chain scheme that allows for multiple devices to be connected to a single UART, many of Pololu's products have it, maybe some Dimension Engineering products but I'm not sure.
-
Thanks for that info. ;)
Joker94
-
on the Atmega 64 on pin 33 and pin 34 there is something i am not sure about.
it says
Pin 33(WR)
Pin 34(RD)
here is the data sheet.
http://www.futurlec.com.au/Atmel/ATMEGA64.jsp (http://www.futurlec.com.au/Atmel/ATMEGA64.jsp)
is this another UART or a function coincidentaly labled the same.
thanks
Joker94
-
@Joker94
You're reading the specs incorrectly. PG0 and PG1 are designated for PORT G. WR is write strobe. RD is read strobe. ALE is address latch enable. These are all used for accessing external memory/SRAM.
The pins you are trying to locate is PE0 (RXD0) / PE1 (TXD0) and PD2 (RXD1) / PD3 (TXD1). Those are the USARTs that are directly available to you.
Of course if you have extra pins you can do some bit-banging to get more pseudo-serial interfaces.
-
thanks rgcustodio
i knew about the others you pointed out i was just not sure if WR and RD were UART as well
thanks very much
Joker94