GeoMessage and Presence tracking

Posted on
Fri Feb 01, 2013 11:08 am
johnprzy offline
Posts: 3
Joined: Feb 01, 2013

GeoMessage and Presence tracking

My name is John Przyborski. I developed the application GeoMessage which has been used by some in this forum for presence tracking.
http://www.perceptiveautomation.com/userforum/viewtopic.php?f=11&t=9441&hilit=geomessage

What is GeoMessage?
GeoMessage monitors geographic areas. When a user enters or exits an area, an email is sent from the background to the specified email addresses. Additionally, GeoMessage allows the user to control 'when' notifications are sent. (Specific days of the week and time range.) GeoMessage was designed to be as efficient as possible to as to minimize battery drain.

Although GeoMessage can be used as an input for a home automation system, GeoMessage wasn't designed to be used this way. In short, technical restrictions on message frequency limit it true capability.

This thread is for discussing a new app which will be suitable for control of home automation systems.

Posted on
Fri Feb 01, 2013 11:14 am
johnprzy offline
Posts: 3
Joined: Feb 01, 2013

Re: GeoMessage and Presence tracking

The big hurdle to get across is how to eliminate the email bottle neck. Right now I'm thinking hitting a URL with specified parameters is the way to go.

What do people think?

Posted on
Fri Feb 01, 2013 11:34 am
nsheldon offline
Posts: 2469
Joined: Aug 09, 2010
Location: CA

Re: GeoMessage and Presence tracking

Indigo provides a RESTful interface via authenticated HTTP (or HTTPS via the Prism Reflector service). I don't have any experience developing for that interface method, but if one were intending to build an iOS app to access Indigo remotely (say to update an Indigo variable or execute an Indigo action group), that'd be the way to do it.

P.S. Welcome to the forum. :-D

Posted on
Fri Feb 01, 2013 12:13 pm
berkinet offline
User avatar
Posts: 3290
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: GeoMessage and Presence tracking

+1 on the RESTful interface &
+1 on the welcome (et Bienvenue)

I have a couple of thoughts on how an HA app should work.

One, there needs to be the ability to define multiple "targets."
Two, the app needs to be always on, that is always looking to see if it is "near" a target.
Three, battery usage needs to be well controlled.

The last two points seem to be mutually exclusive. But, I was thinking the app could normally use Cell Tower location (if that is possible) and then only switch to GPS when within the same tower area as the target. This might requiring some learning on the part of the app. But, if it can be done, it would meet the criteria noted above.

And, finally: Thanks for your offer of help!!!

Posted on
Fri Feb 01, 2013 2:27 pm
roussell offline
User avatar
Posts: 1108
Joined: Aug 18, 2008
Location: Alabama

Re: GeoMessage and Presence tracking

Hi John, welcome to the forum. I'm the guy that sent you to way-too-long list of feature requests. I'll copy the email thread below to bring everyone else up to speed:

Code: Select all

***************************
John,
 Hi, great app. Here's a couple of wishes:

1. Ability to edit the subject line of messages
2. Allow multiple repeats during the same day.
3. The ability to duplicate (copy) already-created messages so you don't have to completely recreate a message from the start if you have several similar to build. If that's too difficult how about the ability to send separate emails for arriving and leaving an area (both contained in one GeoMessage).
4. Option to include other phone info in the message (battery level, today's phone usage time, GPS coords., etc)
5. Save/restore messages to another phone.

**************************

Hi Terry,

Thanks for the email and I'm happy you like the app.

Re: #1 – A number of users have requested the ability to modify the email subject which is something I'm working on for the next release.

Re: #5 – Are you thinking this behavior would be similar to documents in iCloud?

As for suggestion numbers 2, 3, 4... can you explain more about how you're using GeoMessage?  Are you using it to notify friends/family of your location or something else?

John P.

***********************
Hi John, thanks for the reply. Yes, perhaps an explanation of what I'm using the app for would be of benefit. I'm attempting to use the app for location tracking with my home automation system. So for example if I enter or leave the area defined around my house, I'd like to send a corresponding email to an inbox that the HA server watches. Similarly, I'd like to do the same for work and various other places in my normal travel. I'll then display that info on an iPad or similar device in my house using the HA server as the keeper of that info.

So, from my wish-list; #2 would allow my system to know that I've arrived/left the same more location more than once/day. A use-case would be leaving the house and going to work, then leaving work and returning home. Later that evening I leave the house a second time, and go to the store, of course I'll return from the store and arrive at home a second time that same day (hopefully) but the app in it's current state will only show the first arrival/departure and not the second (or subsequent).

#3 just makes it easy to duplicate the messages. So for example; I create a message for leaving the work 'circle' around 12:00 (for lunch) and send an email to somebody. If I wish to create a second 'leaving work' message, but this time for an end-of-work scenario (heading home) I have to completely recreate the message, choosing the 'circle', typing the message, selecting the email, etc. If I could simply copy the first message that I created - the 'lunch' message - and then change the time and/or email body, it would simplify the creation of multiple messages.

The sub-question to #3 involves the ability to send differing emails in one 'message' so, i would like to be notified when I enter a 'circle' AND when I leave (each with a different email and/or subject) the circle. As it stands now, that requires two separate 'messages'. It would be nice to give the option for "enter area", "exit area", and "both" in the 'set region' screen'. If 'both' is selected then that would probably modify the 'Edit Message" screen to have at a minimum two 'Label' and 'Message' entries - one for entering the area, and one for leaving.

#4 is just a "nice to have" - again sending that info to my Home automation system would be cool. I could then have the system to remind me to charge my phone if GeoMessage sends a battery-level warning of <xx% when I arrive home.

#5 Take all of the stuff I want to do above and then duplicate it for my wife's and daughter's phone - I have to do triple the 'standard' messages plus any custom per-phone messages. If there was a way iCloud, XML input via copy/paste from email, bluetooth send to phone, however... it would greatly simplify folks that want to purchase multiple copies and use them for their family/co-workers.

How about three more while I'm on a roll :) -

#6 In addition to sending an email, how about being able to call a URL on a webserver? Using my home automation system as an example - Currently I check for emails once/minute, which is fine for some things, but I can thank of sometimes when that one minute delay would not be advantageous (arriving home in the dark and wanting to turn on the outside lights for example). However, If I wrote a simple PHP web page that parsed the URL query string and then caused the system to react, I could have near instantaneous response. In this example I envision an "Add URL" button below the "Add Email Contact" button on the "Set Message" screen. Selecting the "Add URL" button would present a text box to enter a URL that would be called when the message was activated:

http://<server>/page.php?Message=arriving home

You could optionally include the message label, subject and body as parameters in the query string or make the info user-definable with some optional variables to include:

batt=battery level
label=message label
body=message body
gps=gps coordinates
mph = miles per hour
kph = kilometers per hour

so then if I wanted to send a custom set of info to my server-side php script I might have a URL that looks like this:

http://<server>/page.php?Message=On highway 17 passing Wall-Mart&Battery=<batt>&Location=<gps>&Speed=<mph>

So in that URL Geo Message would place the current values of the battery level and the gps lat,lon (maybe the precision too) in the string, replacing the "<batt>" and "<gps>" place holders. It would also send my custom message "Message" and anything else I placed in the query string. My server-side PHP script would read that as soon as GeoMessage sent it and then act on it as designed.

#7 how about a separate message 'trigger' that instead of sending a message on entering/leaving an area, one that triggers on an "over speed" alert - if my daughters phone (in her purse, in her car) is traveling at more than 70MPH, I get a message.

How about this one: #8 - This plays into #5 and allows coping to multiple devices and changing phone messages on-the-fly. How about the ability to remotely configure the phone by entering a custom web address? The phone could be set to periodically check the address for a new config file. All of the settings available to the user from the phone interface could be configurable from the web address and the file could be a plist, XML, json, whatever. Allow all changes from the config file, even the ability to 'lock' the UI on the phone so changes can't be overridden, and also allow the config file to adjust the time/interval that the app checks for new versions of the config file.

Use case: Let's say I have a small company and I make deliveries. I provide company phones to stay in touch with my drivers (or have iPads with 3G in the vehicles). I want to know when they get their deliveries out on time so I have an application (here's another business opportunity for you) that pulls the day's deliveries from my point-of-sale system, and converts them into a series of config files (one per phone/iPad/driver). The phones are set to pull the config info down once/minute initially so I can insure that they get the correct 'messages' that correspond to their deliveries. Also as the deliveries change throughout the day new remote config files are pulled down by the phones to changes the message as needed. At the end of the day I could send I config file out that clears the day's messages and resets the config check interval to not check until the next morning (either by a long interval of several hours, or a specific time entry)

I think that you could open your app up to a whole different market by doing the above, HA geeks like myself, but also small companies that wish to track their fleet drivers, parents worried about their kids safety  etc. You could even have a separate subscription-based web application to configure the messages that get pushed to the phone (see #8). Keep the ability to specify the config server address and the config file simple to create for hackers/geeks like myself. But if somebody has several phones to configure and no technical ability then paying a little cash for a nice web interface to configure all of the instances of GeoMessage on his/her family's and/or business' phones should be a no-brainer.

Sorry to be so long winded, I hope some of the above helps you out.

Terry


Terry

Posted on
Fri Feb 01, 2013 7:44 pm
bobeast offline
User avatar
Posts: 400
Joined: Apr 16, 2003

Re: GeoMessage and Presence tracking

johnprzy wrote:
The big hurdle to get across is how to eliminate the email bottle neck. Right now I'm thinking hitting a URL with specified parameters is the way to go.

What do people think?


Yeah RESTful is the way to go. It probably cuts down on your server requirements, and Indigo (the REST target) can handle such things as composing an email to send to a spouse, logging the location, turning down the thermostat, etc.

Choose to chance the rapids.
Dare to dance the tide.

Posted on
Tue Feb 05, 2013 5:19 pm
richy240 offline
Posts: 111
Joined: Jul 08, 2012

Re: GeoMessage and Presence tracking

Oh man, this is awesome...

johnprzy wrote:
The big hurdle to get across is how to eliminate the email bottle neck. Right now I'm thinking hitting a URL with specified parameters is the way to go.

What do people think?

This is obviously the preferred method now that everyone knows it's an option. It just hasn't been implemented well from the handset side of things. (Hint, hint!) :D

berkinet wrote:
One, there needs to be the ability to define multiple "targets."
Two, the app needs to be always on, that is always looking to see if it is "near" a target.
Three, battery usage needs to be well controlled.

The last two points seem to be mutually exclusive. But, I was thinking the app could normally use Cell Tower location (if that is possible) and then only switch to GPS when within the same tower area as the target. This might requiring some learning on the part of the app. But, if it can be done, it would meet the criteria noted above.

I don't think these things need to be mutually exclusive at all. Apple already has a framework, called Core Location, that allows location-based actions without serious battery drain (when implemented correctly, I assume), and it's apparent in many apps already. Reminders and Find My Friends are two Apple apps that use background location tracking to prompt actions based on your position, and Instapaper is a great example of a third-party app that does the same thing. (I use all three of these daily. I didn't put a lot of effort into testing GeoMessage extensively for our purposes due to its one-message-per-day limitation, but I suspect its drain is similar to these other apps, which is minimal.) There is an impact on battery life from the background tracking, don't get me wrong, but it's certainly worth the tradeoff if you want location-based actions to fire without manual intervention. It works well and it works right now - this isn't something we have to wait for or experiment with extensively. It's already happening, and it just needs to be implemented in an automation-friendly manner. John probably already knows this quite well - having developed GeoMessage, I assume he is very familiar with the benefits and drawbacks of Core Location.

I do agree, though, that we need to be able to define multiple targets. The GeoMessage app already handles this very nicely, so modeling a new app around GeoMessage seems ideal to me. The fact that you can customize the location radius really makes for a lot of flexibility for actions as the user moves in and out of the defined areas. (It would be nice to re-use these definitions though, regardless of the direction of movement, for precise borders that span more than one action. But that's splitting hairs, I think.) Initially all that really needs to happen, from my perspective, is that the actions that GeoMessage executes (currently, sending emails) need to be converted over to the RESTful URL model. The app is damn near perfect as it is for our purposes; the limitations really only being what's already been discussed here, in other threads and via direct email communication.

Of course, this is all just my opinion. As I've stated before, I am no developer, just a very, very hopeful user.

Posted on
Tue Jun 02, 2015 6:15 am
afulki offline
Posts: 15
Joined: Jun 01, 2015

Re: GeoMessage and Presence tracking

Did anything ever come of this?

I've tried all the plugins, and so far met with little success, I'm sitting looking at the variables for my wife and I, her phone is in the front room and mine in my office, but according to FING we are both away :(

Gary

Posted on
Tue Jun 02, 2015 7:34 am
kw123 offline
User avatar
Posts: 8335
Joined: May 12, 2013
Location: Dallas, TX

Re: GeoMessage and Presence tracking

Depends on the state of the phone and how wifi is measured. iPhones drop off after 5-15 minutes depending on power situation. When router info is used for wifi state (power save mode detection) you get better results for > 2 hours...


Sent from my iPhone using Tapatalk

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 4 guests