Home Arduino A look at a GPS shield for the Arduino

A look at a GPS shield for the Arduino

In this article we look at a GPS Shield which is based on the ublox’s NEO-6M receiver module. Lets look at some info about the NEO‑6 module.

The NEO‑6 module series brings the high performance of the u‑blox 6 position engine to the miniature NEO form factor. u‑blox 6 has been designed with low power consumption and low costs in mind. Intelligent power management is a breakthrough for low‑power applications. These receivers combine a high level of integration capability with flexible connectivity options in a small package. This makes them perfectly suited for mass‑market end products with strict size and cost requirements. The DDC interface provides connectivity and enables synergies with u‑blox LEON and LISA wireless modules.

More info – https://www.u-blox.com/en/product/neo-6-series

It is compatible with the Arduino Uno and Mega type boards. The GPS pins (RX, TX) can be connected to D0-D7 of Arduino via jumpers. Support software SerialPort and it also has a Micro SD card interface.


Parts Required

Description Link
Arduino Uno Arduino UNO R3
GPS shield GPS Shield For Arduino With Antenna SD Slot

Code example

This example prints the output received by the GPS module to the serial port of the arduino.

[codesyntax lang=”cpp”]

#include <SoftwareSerial.h>
SoftwareSerial SoftSerial(6, 7);
unsigned char buffer[256]; // buffer array for data recieve over serial port
int count=0;     // counter for buffer array 
void setup()
  SoftSerial.begin(9600);               // the SoftSerial baud rate   
  Serial.begin(9600);             // the Serial port of Arduino baud rate.
void loop()
  if (SoftSerial.available())              // if date is comming from softwareserial port ==> data is comming from SoftSerial shield
    while(SoftSerial.available())          // reading data into char array 
      buffer[count++]=SoftSerial.read();     // writing data into array
      if(count == 256)break;
    Serial.write(buffer,count);            // if no data transmission ends, write buffer to hardware serial port
    clearBufferArray();              // call clearBufferArray function to clear the storaged data from the array
    count = 0;                       // set counter of while loop to zero
  if (Serial.available())            // if data is available on hardwareserial port ==> data is comming from PC or notebook
    SoftSerial.write(Serial.read());       // write it to the SoftSerial shield
void clearBufferArray()              // function to clear buffer array
  for (int i=0; i<count;i++)
    { buffer[i]=NULL;}                  // clear all index of array with command NULL



Open the serial monitor window in the arduino ide and you should see something like this

$GPTXT,01,01,01,ANTENNA OK*35



Download the software from https://www.u-blox.com/en/product/u-center , install it and connect to your Arduino serial port and the app should display various data regarding your location


You may also like