Debugging UART on a GPS Module using Bus Pirate

A guide to capturing and decoding UART data from a GPS module for diagnostic purposes.

1. Experiment Overview

This experiment uses the Bus Pirate to monitor UART data from a GPS module (such as the NEO-6M) to observe and decode GPS location data. This setup can be useful for debugging, ensuring correct data transmission, and verifying baud rates.

2. Required Components

3. Circuit Setup

Connect the Bus Pirate to the GPS module as follows:

Note: Only connect the Bus Pirate’s RX to the GPS TX if you want to passively read data without influencing the GPS module.

4. Configuring the Bus Pirate

To configure the Bus Pirate for UART sniffing, follow these steps:

  1. Connect the Bus Pirate to your computer and open a serial terminal (e.g., Tera Term, PuTTY).
  2. Set up the serial connection for the Bus Pirate (typically 115200 baud, 8N1).
  3. Enter UART mode by typing:
  4. [m] --> [3] for UART
  5. Configure the baud rate to match the GPS module’s baud rate, commonly 9600 baud, by typing:
  6. [9] for 9600 baud
  7. Set up other configurations as needed, like stop bits and parity, which are often 8N1 (8 data bits, no parity, 1 stop bit) for GPS modules.
  8. Enter UART sniffer mode to start capturing data:
  9. [](space) to start reading UART data

5. Observing and Decoding GPS Data

The GPS module will transmit data in NMEA format, with sentences containing various GPS information such as position, speed, and time. An example NMEA sentence:

$GPGGA,123519,4807.038,N,01131.000,E,1,08,0.9,545.4,M,46.9,M,,*47

This string includes:

Refer to GPS NMEA documentation for detailed decoding of each field in an NMEA sentence.

6. Interpreting and Verifying Data

Common NMEA sentences from GPS modules include:

Using this information, verify that the GPS data is correct by comparing coordinates and timestamps with known positions or times.

7. Tips for Troubleshooting