Go Down

Topic: Problems with serial communication (Read 738 times) previous topic - next topic

Jellycow

Hey!
I'm trying to communicate trough serial between my Arduino UNO and my Arduino Nano by the TX and RX pins, and it seemed to work fine at first, but now it seems like they frequently loose the communication from each other. Sometimes it works, and sometimes it doesn't.
However, when I plug in USB to one, or both of the boards, while still using one of the TX/RX pins, they're always able to communicate with each other.
Both board do also work when just communicating with the computer and not between the two boards.
Since it seems to work with the PC, I'm afraid that there's a defective RX/TX pin on one of the boards.

Do anyone know what could cause this problem?

Thanks in advance

Coding Badly


Jellycow

#2
Jan 15, 2013, 10:13 pm Last Edit: Jan 15, 2013, 10:15 pm by Jellycow Reason: 1
Hum I don't think so..
Which grounds do you mean?

Edit: I've also noticed that the TX LED only blinks when using USB while having the serial monitor open. It does not blink when using battery.

Coding Badly


You have two boards: Uno and Nano.  They have each have a ground.  It's labeled GND.  Is there a wire connecting Uno GND to Nano GND.

Jellycow

I have the GND from the UNO to a breadboard, but nothing to the Nano.
Btw, I'm using the Wild Thumper Controller https://www.sparkfun.com/products/11057, which is from what I've understood a modified Nano.
It doesn't look exactly like the Nano, but is the port named GND same for both?
Why should I connect the GND to each other btw? Should I do the same with the 5V?

Coding Badly

It doesn't look exactly like the Nano, but is the port named GND same for both?


Looks like it from the pictures.

Quote
Why should I connect the GND to each other btw?




A circuit (loop) is necessary for electricity to flow.  TX (connected to RX) and GND form a circuit for sending data from one side to the other.  RX (connected to TX) and GND form a circuit for sending data the other direction.  Without GND, there is no circuit and no electricity flow.

Quote
Should I do the same with the 5V?


If you aren't now then you should not.  You would only connect 5Vs together if you have a single shared power supply.

Jellycow

It worked now!
Thanks a lot, and thanks for the explanation!
A bit strange that it did work sometimes without the GND, but whatever ;)

Go Up