Recieve data from gps.

Hello
I'm simply trying to read from an gps-device but all I get is "mumbojumbo" from the serial monitor. The baudrate is to be honest unclear but I've tried them all but I would guess 4800 or 9600. When I bought the GPS shield the rx/tx jumpers were set to pin 0 and 1. This I changed so rx is 3 and tx is 4. At least that's what I think I'v done.

I took a picture of the board so you can see the pins. According to me the rx would be 4 and tx 3 but then I get the famous "avrdude stk500_getsync() not in sync resp=0x00"

Has someone used the navilock nl-280gg before? I think it should work fine......

What am I doing wrong?

My equipment:
Arduino Uno
GPS Shield Eb-5365 SD
Navilock NL-280GG (Navilock Produkte 60543 Navilock NL-280GG Multi GNSS GALILEO GLONAS GPS SMA 90° Antenne 5 m)

My code:

#include <SoftwareSerial.h>

SoftwareSerial gps(3, 4);

void setup()
{
Serial.begin(115200); 
gps.begin(9600);
}

void loop()
{
if(gps.available()>0)
  {
  char ch=gps.read();
  Serial.print(ch);  
  }
}

Hi,

I had my share of problems when I used the 'normal' UART serial port of the arduino when I let the GPS connected during upload of the code.
The USB uses the same serial port as the UART (pin 0-1), so the upload got distorted by the incoming data from the GPS.
I do not know this GPS shield, but it makes sense, when you change the signals away from pin 0 and pin1 you should not have these problems.

Also it depends if your GPS gives TTL Serial, or a "Serial reprsentation of RS-232" serial.
What does this mean: some GPS modules give the RS-232 signal, but with TTL (0-5V) level.
If this is the case, the data must be inverted.

With RS-232 a 'high' (+12V) is a "low' in TTL (0V), and vice versa.

In my case I used an old TomTom GPS that gave out real RS-232, so from +12V to -12V .
I had to convert this to TTL AND invert the signal.

The ínversion' can be done in software as well, look this up in the data for the softwareserial library.

Quote from: http://arduino.cc/en/Reference/SoftwareSerial

"The SoftwareSerial library has been developed to allow serial communication on other digital pins of the Arduino, using software to replicate the functionality (hence the name "SoftwareSerial"). It is possible to have multiple software serial ports with speeds up to 115200 bps. A parameter enables inverted signalling for devices which require that protocol. "

Read my trials here : TomTom serial GPS mouse re-used for GPS-clock - Networking, Protocols, and Devices - Arduino Forum

Succes,

Satbeginner

You might want to try 38400 baud rate, from a clone datasheet at bottom of this page:
http://www.ebay.co.uk/itm/GPS-Shield-with-SD-Slot-Antenna-for-Arduino-NEO-6M-/131238547921?pt=UK_BOI_Electrical_Components_Supplies_ET&hash=item1e8e6d51d1

Google a tool called "SiRFDemo", or look at: http://www.falcom.de/support/software-tools/sirf/

This gives a good view to what coming out of the GPS, both NMEA (serial protocol) and the binary Sirf protocol.

It even scans the GPS for possible baud rates.

Un saludo,

satbeginner

Can someone take a look at this data from my gps and tell me if its valid?
I'd say that it's invalid because of the missing * at the end. The last two should be the checksum and it should always start with a *. Any guess on why this is missing?
When using the hyperterminal or any other terminal for that matter the * is always missing at the end.

$GPRMC,104321.00,A,5835.25953,N,01611.78154,E,0.348,,280914,,,D2
$GPRMC,104322.00,A,5835.25958,N,01611.78144,E,0.307,,280914,,,D8
$GPRMC,104323.00,A,5835.25965,N,01611.78136,E,0.100,,280914,,,D,

Slow the gps baud rate down to 4800 and see if that makes a difference.

The data puts you near Norrkopping I believe?

That is correct sir :slight_smile: Norrkoping is where I live at the moment :slight_smile:
I will try your suggestion about the baudrate asap!

The data seems to be readable at a baudrate of 38400. Any other then it's just "mumbojumbo".

Post your current version of your code?

It's still exactly as in the first post but the baudrate is now set to 38400.

gps.begin(38400);

Before I get a location fix the data looks more ok.... I think

$GPRMC,,V,,,,,,,,,,N*53
$GPVTG,,,,,,,,,N*30
$GPGGA,,,,,,0,00,

In that case I have no more ideas I'm afraid.

It has nothing to do with functionality but you could reduce the main loop:

void loop()
{
  if(gps.available())
  {
    Serial.write(gps.read());
  }
}