Written by Nathan Cloud on Thursday, 18 Oct 2007.
The Garmin Developer API
So a few weeks back I was playing with mapmyride.com, nice site, good alternative to motionbased I suppose, lots of neat features, then I noticed something: they had the "upload directly from your Garmin GPS device" feature. Just like motionbased.
"Huh? How'd they do that?" I wondered to myself. "Is there an open API for this out there?"
Well, it turns out there is: I give you the Garmin Communicator Plugin API. And it is a beautiful thing. It is distributed under an open source license, it is neat, it is a smart thing to do (IMHO), and the Garmin developers are active in the (currently very small) community of users. I have to give Garmin props on this, a lot of times API's like this would cost you money, or licensing fees, what have you.
It's Business Time
So I spent the next week trying to get this thing to work, they provided a few examples, some basic, some really overboard, but none really doing exactly what I needed it to do: to allow you (my cherished users with GPS devices) to plug your Garmin GPS into your computer, then log onto Crankfire and seemlessly upload tracks and waypoints directly into the Crankfire system. We don't need no stinkin' 3rd party software!
So, after another week, finding a lot of the documentation a little vague (probably the fault of my tiny brain), looking at other peoples code, hacking the heck out of their example code, I was able mash together a working prototype doing exactly what I wanted to do.
Just look at that. It's beautiful, isn't it? Right at the top of the normal data upload page, you can click a link which will take you to our Garmin Web Uploader. It will then look for your GPS, download the data on it, and give you dropdown box listings of every track and waypoint on your GPS. Selecting them will let you see them on that little map there, and if you find the data what you want to upload, with the click of a button you are well on your way to help make the world a better place.
The Fine Print
As with most every feature on this site, this is very beta, it may work perfectly, it may half work, it may not work at all. You will also need to install the Garmin Communicator Plugin and you will need a compatible Garmin GPS unit. If you have a LOT of data on your GPS device, it may run slow, it may crash your browser, it might give you warts. I dunno.
At very least, for some of you, this simplifies the process for uploading data to this site. Which is a beautiful thing.
The API also has an interface for uploading data to your GPS.