My wife is doing an endurance cycling event in the near future, and so I was inspired to create a public live-tracking map to relay her progress to others. It wasn’t too hard to set up; if you have a SPOT tracker, follow the instructions below. These instructions can be modified to take an SMS text as well, as long as the formatting remains constant.
0. Make sure your SPOT device is sending emails to the gmail address you have set up for IFTTT.
1. Set up an IFTTT action like this:
– Trigger: new email from ________ (in my case, the source of the SPOT email)
– Action: add row to spreadsheet.
– Formatted row: {{ReceivedAt}} ||| {{BodyPlain}} ||| =(split((TO_TEXT(INDIRECT( ADDRESS( ROW( ) ; COLUMN( ) -1)))),” :”))
This format takes the received time and the body and then splits the body according on two characters, ‘ ‘ (space) and ‘:’ (colon). This is due to the way the email is formatted. The neat “take the column before this one” function I borrowed from another IFTTT action.
2. Run the action once and open up your new Google Drive spreadsheet.
– Add a header row and fill it in. Call the first column “title” and then find which columns contain the latitude and longitude and label them respectively. You will have a bunch of columns because of the length of the email body. I would tell you which column numbers to name, but it depends on the number of words in your SPOT device name.
– Fill in the rest of the header row with something for each column that has a value in it (this is so Google Maps can process the spreadsheet). I chose to call all the non-vital columns “ignore”. As long as you leave the header row, you can clear this spreadsheet as often as you like, and IFTTT will just add new data to the first empty row.
3. Head to the Spreadsheets Map Wizard at http://gmaps-samples.googlecode.com/svn/trunk/spreadsheetsmapwizard/makecustommap.htm and follow the instructions. This is where you actually build the map. (I am not responsible for that site.)
4. Copy the output from the Spreadsheets Map Wizard into a new .html file and upload it to a server somewhere. I suppose you could theoretically even share it online via Dropbox.
5. Success (I hope)!
Obviously, there are a lot of places this workflow can go wrong, so take your time and double-check each step before moving on. Note that the spreadsheet wizard may stop working soon because Google is dropping v2 of the Google Maps API sometime “in early 2013.” I can’t guarantee I’ll be able to update my map to v3 of the API because I’m not the greatest with javascript.
My finished product (with some extra KML layers) is here: http://mattbk.com/~matthewbk/warrior.html