Santa Tracker - a Christmas iFindStuff Version

Posted on
Mon Dec 07, 2015 7:32 am
Chameleon offline
Posts: 611
Joined: Oct 04, 2014

Santa Tracker - a Christmas iFindStuff Version

NOTE: YOU DON'T NEED AN IPHONE, AN APPLE ACCOUNT OR IFINDSTUFF TO INSTALL THIS PLUGIN

Ok - now that's settled - Hi and welcome to the season of goodwill and all that :D

Well at this time of year I get to thinking about the big event: having all the family home, shopping, turkey & all the trimmings, the tree and, of course, presents and Santa Claus (aka Father Christmas). I also think that Indigo just doesn't get involved enough in the Christmas spirit and that there is so many things it should be doing on Christmas Night. Questions such as: When should I turn the lights and heating on for Santa to make it easier for him (and add to my 'nice' rating)?, Shouldn't we get a warning when he's getting close so that the kids can get to bed and asleep?, Can I make sure the Alarm is off just before Santa arrives so that he doesn't set off my zoning alarm?, Should I turn my Christmas Lights on to welcome him just before he arrives and then turn them off when he leaves?, What route does Santa take?, How many presents does he actually deliver and How many cookies, carrots and milk are consumed along the way?

Now I've read the forums and Matt & Jay have been talking about Indigo 7 and all of the new functionality & devices it will provide. However, despite a detailed search I can find no mention of any additional functionality that's coming to resolve the 'Santa Question' and I feel that's a glaring omission that's never been properly tackle by any Home Automation software.

So being a Brit (and hence eccentric and a bit odd) I decided to release a plugin for Indigo 6 to provide unique functionality in the Home Automation Marketplace and a real USP - The Indigo/iFindStuff Santa Tracker :mrgreen:

What does it do?

In test mode the plugin utilises a simulated NORAD tracking feed or in real mode a real-time NORAD update for the actual Christmas Night version. The Beta is intended to get you to prepare for Christmas Night (create triggers, control pages or schedules) using the simulated tracking feed. If you run the plugin in real mode then Santa will stay at the North Pole until NORAD notes that he's left on 24th December which won't be much of a test :D

The plugin utilises the functionality of iFindStuff to track Santa (or more accurately his sleigh) over Christmas Night. You DON'T need to have iFindStuff installed, nor any of the functional libraries or icons that plugin requires - Santa Tracker is a standalone plugin that you simply install in the usual way. If you want to display or use Maps you will need to grab yourself a Google API key. You can find out how from this forum post - http://forums.indigodomo.com/viewtopic.php?f=181&t=14734. You'll need this key when you configure the Santa Tracker so get one before you start. It's free and easy to obtain & authorise and I haven't heard of any users of iFindStuff who've had a problem with it. If you've already got iFindStuff installed you can simply copy the key you already have from the iFindStuff configuration dialog.

All the information that you need to set up the plugin, and some background information on Santa's route & sleigh can be found in the special manual I've written to support the plugin. You can view/download a copy from this link:

https://www.dropbox.com/s/rosbk0iilnwxw0z/Santa%20tracker.pdf?dl=1

It takes you through the installation, configuration of the Santa Tracker, creating your first sleigh and running the simulation including maps and reporting. It contains a full feature list. The only things I would highlight are: a) Having a Google API key is now mandatory (it used to be optional) so get one and b) a good value to enter on the configuration dialog for the number of milliseconds that represents 5 mins in the configuration dialog is 5000ms rather than the 1000-2000ms that the manual suggests we've discovered in testing

If you get any problems - drop me a line.

I've also included in the download instructions a copy of the information for my control pages. If you save the file, create a new control page and then drag the file onto the canvas it'll add all of the information you see in the control page below. I originally created the page for an iPhone 5S Landscape resolution so you might want to alter the page size accordingly. I've found that this control page works well on iPhone 4 - iPhone 6 Plus as well as my iPad. All you need to do is change each of the controls/information so they point to your sleigh device that you've created as part of the installation rather than mine! Otherwise you can just create your own pages.

If you're not sure how to add a 'Refreshing URL' control for the map images you can check the process in the iFindStuff manual where a step-by-step guide is provided.

https://www.dropbox.com/s/jbabhg3zd5w92jl/iFindStuff%20Manual.pdf?dl=1

Here's what my Santa Tracker Control Page looks like:

Screen Shot 2015-11-22 at 13.09.03.png
ST Control Page
Screen Shot 2015-11-22 at 13.09.03.png (834.33 KiB) Viewed 2404 times


As you can see it provides a wealth of information on Santa's route, statistics on his Sleigh and Reindeer, nice/naughty/awake children tracking, estimated time of arrival & distance to your home and vital analysis of the number of presents, cookies, milk and carrots being consumed. The route is provided from a live feed from NORAD who actively track Santa on Christmas night.

You can even generate reports and a map of where Santa is and where he's been from the Plugins/Santa Tracker menu options. Just give them a go once you've got everything started.

Here's an example of a real time Santa Tracking Map:

Screen Shot 2015-11-22 at 13.26.48.png
World Map
Screen Shot 2015-11-22 at 13.26.48.png (618.68 KiB) Viewed 2404 times


and a Tracking report on progress to date:

Screen Shot 2015-11-23 at 18.17.47.png
Reporting
Screen Shot 2015-11-23 at 18.17.47.png (120.93 KiB) Viewed 2404 times


In recent weeks a small, but select, band of developers and users from across the globe have been Alpha testing the plugin. I'm really grateful to all of them for being such good sports and giving me lots of great feedback and ideas. It was important to get a wide range of diverse users because the Tracker is reliant on timezones, which Santa uses to maximise present giving opportunities, and it needed to work in any country worldwide. As a result of their efforts and dedication I'm releasing the Beta version today. I need to make sure that it works "on the night' because we only get one shot so the version that's being made available provides a test simulation of the plugin using NORAD data from last year. Santa doesn't appear to like change much because checking his route since 1995 he appears to go to the same stopping points within 5 decimal places on the Latitude and Longitude so it seems like a reasonable test :wink: On the night you'll have a choice of an historical or real time feed as a contingency.

What's this all about?

There are a number of reasons why I'm releasing this plugin:

    1. It's fun, eccentric and unique in the HA space (which is a good enough reason on it's own)

    2. I have a lot of iFindStuff users who have provided me with a lot of support in the last 6 months and this is a way to say thanks

    3. I'm going to work on a 'Indigo plugin developers guide' in the new few weeks and I wanted a 'Device' that everyone could understand and follow to demonstrate the power of Indigo. If you have a look at the code you'll notice that I've documented it a lot more than I usually would to make it easier to follow and understand. The plugin guide will draw on this plugin and show how to build a plugin from scratch and assuming no knowledge

Frequently asked Questions

Where can I download it?

You can download the latest version of the plugin from this link:

https://www.dropbox.com/s/51b1iiuh5ok9asg/SantaTracker.zip?dl=1

How do I use it?

I've written a special manual for the plugin which you can view/download from this link. It covers everything that I think you need to know.

The latest version of the manual can be downloaded here:https://www.dropbox.com/s/rosbk0iilnwxw0z/Santa%20tracker.pdf?dl=1

The latest control page template can be downloaded here: https://www.dropbox.com/s/znarhlzmj8o2ce4/SantaTrackerCP.textClipping?dl=1

You might also want to reference the iFindStuff manual sections on creating control pages and using maps. You can find that manual here:

https://www.dropbox.com/s/jbabhg3zd5w92jl/iFindStuff%20Manual.pdf?dl=1

You'll also find the answers to some of your questions in the iFindStuff forum here:

http://forums.indigodomo.com/viewforum.php?f=181

How do I provide feedback?

There's a special forum post (Santa Tracker Beta Feedback) that you should post your bugs, issues, ideas and suggestions in as well as any comments or praise :wink:

Do I need iFindStuff or an iPhone?

No. I wanted the plugin to be accessible to as many users as possible. There's no need for an iPhone as you can display the control page in Indigo Touch like I do or on the web. The plugin doesn't share any information with anyone so you don't need an Apple Account or any other such thing. Although it uses the functionality of iFindStuff it's fully independent so you don't need to install that plugin to get all of the functionality of the Santa Tracker. Finally, you don't need to install any special libraries or files (including icons of Santa on maps) as the package is self-contained.

Why do I need a Google API key?

The plugin uses the functionality of Google Maps and Google Static Maps to provide maps for control pages or the menu Plot Santa's Route option. In recent months, Google have now requested that all users of the Google Maps APIs must get an API key so that they can control usage on their servers. You're allowed to make 25,000 API calls per day which is more than sufficient for the Santa Tracker to do it's stuff even if you have iFindStuff running as well. Getting an API key is easy, free and simple to add to the plugin. Once you have a key you can cut and paste into the appropriate field on the Santa Tracker dialog.

The maps aren't displaying - or the reports!

The most common, by far, issue I have to resolve on iFindStuff is people getting the name of the folder location incorrect on the configuration dialog. Most common mistakes are: a) mis-spelt, b) not making sure the case is correct, c) forgetting to provide the whole path (e.g. /Users/Michael/Maps), d) adding a '/' on the end, e) the folder doesn't exist and finally f) not having write access to the folder. Please check these before you raise a bug if possible :D I'll help you resolve the issue I promise but these will be the first things I check.

The second most common issue is an absent or incorrect API key. Please cut & paste the key from your Google Account rather than typing it. Make sure that you don't accidentally add it twice (I've done that) and there aren't any leading/trailing spaces.

Can I specify when Santa should arrive?

Yep. When I used the NORAD Tracker (http://www.northpole.com) I used it to show my kids that Santa was arriving soon and they needed to get to bed & asleep. Actually, all three of them, now in their 20s, still watch the site as a traditional each Christmas. The only feature that was missing was the ability to tell Santa when to arrive at my home at a given time. This feature does exist in the Indigo Santa Tracker as you can tell Santa the expected bedtime as part of the configuration and the tracker will make sure that he arrives pretty close to that time (based on conditions of course).

Does it account for my timezone?

Yes it does and that was an important part of Alpha testing. It works on your local time and adjusts the NORAD numbers to suit you.

How does it know where I live?

As part of the configuration you specify the latitude and longitude of your home, it's name and when you'd like Santa to arrive. I guarantee that he will make a special stop at that address just for you :D. There's a button on the configuration dialog that opens a web page to help you do this so don't worry if you're not entirely sure of the current lat/long of your address! Just make sure that you transfer the numbers correctly, to the right fields and include any '-' signs. If you don't the plugin will probably think you live in the middle of the Atlantic (which is fine if you live on a trawler in the middle of the ocean but not a lot of people do)

Will there be any other releases?

Yes. This first round is to test the overall code and functionality. Once I've had all of the feedback I'll produce a special version for Christmas Night which will contain a fully updated REAL mode and prepare you for the big event. You'll get notice of when this is ready and any special instructions. I don't intend to change any fields so your control pages, triggers, schedules, etc... should work just fine!

This is bizarre - you know that?

Yep - but then that's a trait of mine :roll: I think that having fun and being whimsical is important as being serious and worrying about what's happening in the world. This is clearly an example of the former.

There is a more serious reason for this plugin. I wanted to demonstrate that almost anything can be a device in Indigo and can be managed effectively by Indigo as part of your system. I'll release the plugin guide manual later in the month and this plugin will be the basis for the practical approach. I also wanted to thank all of my NEST Home, iFindStuff and LED Manager users for their patience and support in the last 12 months.

Finally, I wanted to thank Matt & Jay for all of the effort they've put into this package, customer service and community. I'm sure that Santa will have both of you on the Nice list this year.

Happy hols

Mike

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 3 guests