Parallax GPS Module Tutorial with Nano Problems

Howdy all. I'm trying to use the Connecting a Parallax GPS module to the Arduino tutorial - arduino.cc/playground/Tutorials/GPS - with an Arduino Nano. I'm using an EM-406A GPS unit, but seeing as the setup only requires a NMEA input on a single pin that shouldn't be an issue.

In its original form the code gives an error. This was resolved by replacing printByte(byteGPS) with Serial.print(byteGPS, BYTE), as described in this thread - arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1226544759 However, while the code is uploaded successfully after doing this, the board doesn't seem to be doing anything. There's a brief flash of the TX LED when first run and the serial monitor window shows the single character ΓΏ. The window is set at 9600bps. After that, there's no further activity. The onboard pin 13 LED stays permanently lit and there is no activity from the RX LED.

I'm wondering if the problem is with the use of the RX pin, as the reference page says that neither the TX or RX pins an be used when using serial communication commands. I hooked up the output of the GPS to the RX pin as per the instructions of the tutorial. I also tried it on a different pin and changed int rxPin = 0 to reflect that. However, there was no change.

Has anyone got any ideas on what the problem may be and possible solutions?

P.S. Sorry about the links, but it wouldn't let me post them without any prior posts.

Have you connected the arduino ground to the GPS ground?

You can't swap around the arduino pin you are receiving data on - the code uses the arduino built in serial port, which ONLY recieves on pin 0.

The comment that says you can't use the TX or RX pins while communicating with the board is saying that you must disconnect the GPS from the arduino when you are uploading a sketch. While you are uploading a sketch, the arduino is using the RX and TX pins, so any other data coming in on the RX pin from your GPS will cause the upload to fail.

Have you connected the arduino ground to the GPS ground?

No, the GPS engine is being powered externally. The only connection to the Arduino is the data connection going to the RX pin.

Following the advice in the thread detailing the replacement of printByte, I did upload with the RX disconnected. Didn't make any difference.

No, the GPS engine is being powered externally. The only connection to the Arduino is the data connection going to the RX pin.

Doesn't matter where it's powered. A signal is a voltage, and a voltage is a potential difference. There must be some reference to which this difference is compared - that's ground.

If you have only 1 wire between the GPS and the arduino, it will never work. You must connect the grounds together to have a hope of ever communicating.

-j

Aha! Thanks kg4wsv, that got it working. As you may have gathered, electronics is not my primary area of expertise. I appreciate the help.

No problem, it's a very common misunderstanding. I've seen our electrical engineering students fail to connect grounds.

It probably isn't helped by the way we draw circuits. The ground is usually connected in so many places, we use a symbol (many copies of it) rather than showing the actual wire. If we used a wire many schematics would become unreadable, but it seems to cause novices to overlook this rather important connection.

-j

I think the problem arose from the fact that the tutorial showed the GPS unit being powered directly by the Arduino, but I couldn't do that in my case because the GPS has a higher draw than what the Nano's specs states it outputs. I didn't realise when powering it externally I'd still have to connect the ground to the Arduino.

Thanks very much for your help with that kg4wsv. Jason and I were getting pretty frustrated with it.

Appreciate it.

Oh and thanks also to trialex.

This forum is great.