Pages: [1]   Go Down
Author Topic: Problems with serial communication  (Read 675 times)
0 Members and 1 Guest are viewing this topic.
Sweden
Offline Offline
Newbie
*
Karma: 0
Posts: 39
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

Global Moderator
Dallas
Online Online
Shannon Member
*****
Karma: 210
Posts: 13030
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset


Are the GNDs connected?
Logged

Sweden
Offline Offline
Newbie
*
Karma: 0
Posts: 39
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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.
« Last Edit: January 15, 2013, 04:15:09 pm by Jellycow » Logged

Global Moderator
Dallas
Online Online
Shannon Member
*****
Karma: 210
Posts: 13030
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset


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.
Logged

Sweden
Offline Offline
Newbie
*
Karma: 0
Posts: 39
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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?
Logged

Global Moderator
Dallas
Online Online
Shannon Member
*****
Karma: 210
Posts: 13030
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

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.
Logged

Sweden
Offline Offline
Newbie
*
Karma: 0
Posts: 39
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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

Pages: [1]   Go Up
Jump to: