ESP32 Thing Motion Shield Hookup Guide

Contributors: MTaylor
Favorited Favorite 2

Logging a Journey

Putting all the concepts from this hookup guide together, a data logger can be built that saves IMU and GPS data. For your consideration, a simple example exists in the software folder of the Motion Shield's GitHub repository.

The program collects the GPS data as strings of NMEA data, and the IMU data as CSV. It uses the FileSerial library to create two sets of files, one for GPS data and one for IMU data. What to do with the data is up to you, but let's take a look at the GPS data and graph it.

This is what the GPS NMEA messages look like:

The data is given to a tool such as the GPS Visualizer, which can create various types of data. Outputting as GPX format, the data can be passed to a map web application.

And finally, the GPS track can be viewed.

Example Data Logged on a Map

Taking a trip from Denver to SparkFun. Example data logged and mapped with the GPS Visualizer on Google Maps.

GPS Visualizer can also produce data that can be used in Google Earth, and has a bunch of options. If you've never used GPS data before, it can be super helpful to demystify all the terminology.