Owntracks - accuracy of regions


I’m using the Owntracks app on my phone to keep track of my location. I capture both region-events (using a switch) as read out the GPS coordinates. However, this information seems to be conflicting sometimes. In some cases, the presence-switch shows I’m away, while the GPS coordinates are clearly within the specified region.

These are the involved items:

Switch   mqtt_PhoneDries_Region_Thuis "Telefoon Dries [MAP(thuis.map):%s]" { mqttitude="mosquitto:owntracks/dries/phone_dries/event:Thuis" }
String	 mqtt_PhoneDries_PositionRaw "Telefoon Dries - Raw Data [%s]" { mqtt="<[mosquitto:owntracks/dries/phone_dries:state:default]" }

Both items are receiving their data fine.
The radius for “Thuis” is set to 100 meters (approx 330 feet). I would think this is sufficient margin (I don’t live in a mansion).

Using loginfo I can see that at the time when “mqtt_PhoneDries_Region_Thuis” is switched OFF (which means I’m outside the region), the GPS coordinates provides by the other item are still within that region. Also vice versa: when I get an update of GPS coordinates within that region, my switch remains off.

This doesn’t always go wrong. But these inconsistencies make it quite hard to build some additional logic in OpenHAB based on me (or others) being home.

Do other have similar experiences?

I never looked into it that closely but yes, that is my experience with owntracks, ifttt, and the autolocation Tasker plugin. It takes too long to update and actually a smaller geofence behaves worse than a larger one because of inaccuracies in GPS overall.

You may want to look into Ibeacons then. See http://jpmens.net/2015/06/03/beacons-in-the-office/. Mine just arrived, have not played with them yet.


Thanks both for your input.

My use case currently does not require a very accurate geofence. I wanted to set up a logic that, when all inhabitants are away from home (for let’s say: 30 minutes), certain actions kick in:

  • A message to (some of) the residents saying “you didn’t turn on the alarm” (if alarm = off);
  • Start presence simulation;
  • Turn off certain devices (radio,…);
    Also, when someone is at the front door (rings the bell), a messages would need to be send when we are away.

I can live with a delay in OpenHAB being notified about us being away. But what I can’t understand is that Owntracks transmits conflicting messages (me being in that region - and updating the GPS coordinates being outside that region).

Sometimes there is a ‘hickup’. Even when I’m inside the region, Owntracks thinks I’m in - I’m out - I’m in again. This all happens in a few minutes. So I was considering to use proxy-items combined with an expire binding. Only if we are outside the region for at least x minutes, then we are really outside.

@sandervd: thanks for the link. I’ve seen some beacons in the past, but these seem to be more interesting. I’m not a fan of battery driven devices in my home automation set-up, but I like the “blukii Smart Beacon / EU” which you can plug in a wall socket.

One thing to check is the accuracy (acc in your Owntracks payload) of your location reports. Because Google uses WIFI APs and cell towers, as well as GPS, I often see very inaccurate (i.e. high acc value) reports stating my position is many 100ms away from where I actually am.

There is a setting in the latest versions of Owntracks which let you ignore inaccurate report for this very reason.


The hiccup might be explained by the way Owntracks works; see the first paragraph here: http://owntracks.org/booklet/guide/whathow/

Thanks both!

Another example of an inconsistency: today I left the house for 43 minutes, to a destination that was 6.4 kilometers away (approx 4 miles).

The input coming from “mqtt=”<[mosquitto:owntracks/dries/phone_dries:state:default]"" was pretty/sufficiently accurate. But according to “mqttitude=“mosquitto:owntracks/dries/phone_dries/event:Thuis”” I never left home.

I’m not sure which settings in the Owntrack app could reduce these kinds of inconsistencies?

There’s a couple of parameters to tweak to have an effect on accuracy and reporting frequency in the advanced options menu.
And you need to have set the waypoints to ‘Shared’, did you ?
The OH1 binding docs mention this is required in order to make the binding properly parse MQTT and switch the item.

My waypoints are indeed set to “shared”. The thing is: I get updates, but the accuracy isn’t great at all (see example above).

I know about the advanced settings in the Owntracks app. Would you mind sharing some “best practices”? This could reduce my trial-and-error period. E.g. the “Ignore inaccurate locations” has a default value of “0”. But I’m not sure if this is a boolean value (1 = yes) or a number is expected. I guess the latter. But in that case, what kind of numbers are expected here? How should I interpret them?