EM-406A + Laptop Data Logging Code

Me and a friend went geocaching on bikes with my laptop and recorded this using a EM-406A GPS module (didn’t find the cache, will try again later).

Here’s a picture of the path on Google Earth (see file named “example trip.kml”)

http://i156.photobucket.com/albums/t31/ … ching1.png

This was done in Processing ( http://processing.org/ , you need to know some Java), code in zip file, does not work with anything that’s not 4800 baud unless you change two lines of code.

Sorry the code is not the best

ZIP File Link:

http://frank26080115.thespudmall.com/gps_logger.zip

It’ll log into a file called positions.txt, copy and paste what was logged into the “GPS Path.kml” file included in the zip file in between and to make a path file Google Earth can display (if you used “GPS Path.kml”, it should already be a 3 pixel wide red line, you can configure it with different styles, and also disable altitude while in Google Earth).

You can mod my code. If you enable some more NMEA message (look under the GPSInit function, use NMEASetMsgRate to specify what data you want), you can grab data like speed and stuff. Everything is automatic as long as your code (as in what you want my software to do) goes in the draw function where the debug section is, look in the “variables” file to see the names of the variables all the data are stored in.

You need a GPS module connected to a serial port on your computer, I used a EM-406A GPS module and a FT232R breakout board (USB to serial port converter) from Sparkfun. I love both of these things.