The following shows quickly getting a NEO-6M GPS receiver running.
Manufacturer Details
The NEO-6 module series is a family of stand-alone GPS receivers featuring the high performance u-blox 6 positioning engine. These flexible and cost effective receivers offer numerous connectivity options in a miniature 16 x 12.2 x 2.4 mm package. Their compact architecture and power and memory options make NEO-6 modules ideal for battery operated mobile devices with very strict cost and space constraints.
NEO-6_DataSheet_(GPS.G6-HW-09005).pdf (866.1 KB)
u-blox6_ReceiverDescrProtSpec_(GPS.G6-SW-10018)_Public.pdf (3.7 MB)
Diagram
Pin Wiring
I put it to 5v, but the spec sheet says to do 3.3v so listing that as the pin to use
Arduino | Neo-6pm |
---|---|
3.3V | VCC |
GND | GND |
D13 (pwm) | TXD |
D4 | RXD |
- | PPS |
The PPS min is for Pulse-per-second, but I didn’t use.
Code
#include <SoftwareSerial.h>
const unsigned long TX_PIN = 13;
const unsigned long RX_PIN = 4;
const unsigned long BAUD_RATE = 9600;
SoftwareSerial ss(TX_PIN, RX_PIN);
void setup(){
Serial.begin(BAUD_RATE);
ss.begin(BAUD_RATE);
}
void loop(){
while (ss.available() > 0){
byte gpsData = ss.read();
Serial.write(gpsData);
}
}
Which when connected resulted in
$GPGGA,,,,,,0,00,99.99,,,,,,*48
$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30
$GPGSV,1,1,00*79
$GPGLL,,,,,,V,N*64
$GPRMC,,V,,,,,,,,,,N*53
$GPVTG,,,,,,,,,N*30
$GPGGA,,,,,,0,00,99.99,,,,,,*48
$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30
$GPGSV,1,1,01,03,,,27*7E
$GPGLL,,,,,,V,N*64
$GPRMC,,V,,,,,,,,,,N*53
$GPVTG,,,,,,,,,N*30
$GPGGA,,,,,,0,00,99.99,,,,,,*48
$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30
$GPGSV,1,1,00*79
$GPGLL,,,,,,V,N*64
$GPRMC,,V,,,,,,,,,,N*53
$GPVTG,,,,,,,,,N*30
$GPGGA,,,,,,0,00,99.99,,,,,,*48
$GPGSA,A,1,,,,,,,,,,,,,99.99,99.99,99.99*30
$GPGSV,1,1,00*79
$GPGLL,,,,,,V,N*64
Which doesn’t look like it got a connection to a satellite.
$GPGGA is the basic GPS NMEA message.
NMEA Data
$GPGGA,,,,,,0,00,99.99,,,,,,*48
Which would be
- Time at location in UTC
##::MM::SS UTC
- Latitude,N\S
- Longitude,W\E
- Fix Quality
- Number of Satelites
- Horizontal dilution of position
- Altitude meters above sea level
- Mean sea level (?)
- empty
- empty
- Checksum