May
13
2009

Order Tara's Bicycle Touring Cookbook Today!

Garmin Tracks & Google Maps

by Tyler

Our GPS unit records our position every few seconds while we ride to a 'track log'. We have been downloading these tracks nightly to keep a record of our journey. I have been meaning to hook this information into our google map for a few weeks now and finally had the chance to do so today! If you look under our 'last seen' map there is now a dropdown box that will allow you to select any riding day and load it into the map.

In case you're wondering why they aren't all there by default it is because loading all of our riding tracks which are comprised of thousands and thousands of GPS points would make for a very slow home page. Eventually I will write something which will make it easy to view a tracklog for any given day from within our journal too. Feel free to peer into our route, wrong turns and all.

For the more technically oriented:

We are downloading our tracklogs from a Garmin GPSMAP 60CSx into MapSource nightly. From there we save the tracks as a tab delimited text file and upload them to our webserver. I have written a script that looks at each line in a given track file and creates a google maps polyline using each lat/long point from the track file. In an effort to decrease the amount of points the map has to render I have thrown away any point where the distance travelled from the last is less than 100ft.

If someone out there would like a sample of the code feel free to contact me!