# \[APP\]\[Pro\] Location and Presence (Owntracks)

**URL:** <https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126>\
**Category:** Apps\
**Tags:** app, tools, presence, howto\
**Created:** [December 8, 2018, 6:56pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126 "2018-12-08T18:56:48Z")\
**Posts on this page:** 20\
**Page:** 3

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 4, 2019, 1:59pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/46 "2019-02-04T13:59:53Z")

</div>

ssh to the NAS, type “ifconfig -a [enter]” and see how the various interfaces are configured. Or, use your phone connected to the same network and with an app like ‘fing’ find out what seems to be the NAS.

---

<div class="post-metadata">

**Author:** ![Raytestrak](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/raytestrak/32/3299_2.png) [@Raytestrak](https://community.homey.app/u/Raytestrak)\
**Post date:** [February 4, 2019, 2:35pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/47 "2019-02-04T14:35:26Z")

</div>

I’d rather use MQTT broker on Homey, since Mosquito has no gui. Maybe I’ll try it someday, but first I have to make sure private http works flawlessly. I went to work today and Owntracks knows I’m at work, but Homey (Location & presence) still thinks I’m at home. I wish I was too, but that’s a different matter.

I went to a friend Saturday and it worked fine then.

---

<div class="post-metadata">

**Author:** ![Vondel64](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/vondel64/32/63505_2.png) [@Vondel64](https://community.homey.app/u/Vondel64)\
**Post date:** [February 4, 2019, 4:08pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/48 "2019-02-04T16:08:25Z")

</div>

I have installed the app and connected it with mqtt.  
The problem is that added geofence are not visible in owntracks.  
When I add a geofence in Homey I cannot add the coordinates.

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 4, 2019, 4:31pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/49 "2019-02-04T16:31:16Z")

</div>

That can have several causes. First your location accuracy was bad and the leave event was ignored. Also connectivity problems can be a cause, but then the message should be send as soon as the connection is back again.

For those situations i was experimenting with the inregions field that is send with regular locations events, but cant get that to work reliable. If you have often these kind of problems, try enabling inregions.

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 4, 2019, 4:31pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/50 "2019-02-04T16:31:40Z")

</div>

You can see your location in settings?

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 4, 2019, 7:36pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/51 "2019-02-04T19:36:31Z")

</div>

> [@scanno](#):
>
> you can push way points from homey to connected phones (to sync the fences)

How can I sync those on an iPhone? The screenshot from Android show an advanced setting, on the iPhone I don’t see something that publishes my ‘home’ geofence to other phones. The homey knows about it, the phone that configured it knows about it, but the second phone does not show this geofence. Can I push it from the 1st phone or homey app? Force get it on the second phone?

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 4, 2019, 8:11pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/52 "2019-02-04T20:11:23Z")

</div>

Ah you want to push to other phones? Go to the settings page of the homey app.  
In the overview tab you will see the most actual data of the knows users. At the right side you wil see a button that says ^ by each line. Press it and it will send the data of the geofences to that phone (only MQTT for now)

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 4, 2019, 8:19pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/53 "2019-02-04T20:19:47Z")

</div>

Ah! Thanks. That phone is en route now, so I will have to wait for a check if the app is showing the fence. This is the screen scanno is talking about:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/2X/7/7a5bc847de8d411598e5fe30d58337a869bd7427.jpeg)

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 4, 2019, 8:30pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/54 "2019-02-04T20:30:00Z")

</div>

If it does not show, the device has to accept remote commands. Its a setting somewhere on the phone app.

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 4, 2019, 8:31pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/55 "2019-02-04T20:31:52Z")

</div>

Only on Android under Advanced. This option is not available on the iPhone.

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 4, 2019, 9:34pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/56 "2019-02-04T21:34:17Z")

</div>

Nope. Did not work. I see the cmd command in the communication but the owntracks app on phone 2 does not add the geofence. I clicked the arrow next to phone two since that is the phone that needs the waypoints. As a quick fix I exported the waypoint in my settings screen and send them with airdrop to phone number 2. If it can not be send as it should, then we should send it as it can… Let’s find out if this exported geofence is triggering flows…

---

<div class="post-metadata">

**Author:** ![Raytestrak](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/raytestrak/32/3299_2.png) [@Raytestrak](https://community.homey.app/u/Raytestrak)\
**Post date:** [February 5, 2019, 6:11am UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/57 "2019-02-05T06:11:04Z")

</div>

Yesterday we went away and it worked fine (both leaving and coming home). This morning I went to work and Owntracks knows I’m here, but Location & Presence did not get updated. I’ll try turning inregions on and see what happens.

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 5, 2019, 7:14pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/58 "2019-02-05T19:14:18Z")

</div>

After leaving the ‘ported’ home geofence once, everything is working fine!

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 9, 2019, 1:06pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/61 "2019-02-09T13:06:39Z")

</div>

After testing it for a couple of days, I do have some questions. I’d like to compose a geofence within a geofence. It is nice to have a flow arriving in town (to flow the thermostat) with like a geofence of 5 miles around home, and within geofence town a geofence home with a 300 feet radius (and flow the normal presence items). When I configure that, the combination owntracks/homey is becoming a bit unpredictable. Like when leaving home it is mentioning arriving in town, which is odd, since I already was in town. Yet it is not mentioning leaving home and hitting my presence update flow.

Am I too greedy? Should I just make a couple of geofences on the entrance ways into town or is my geofence within geofence a scenario that actually should work and just needs some more debugging?

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 9, 2019, 1:43pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/62 "2019-02-09T13:43:12Z")

</div>

At the moment you are too greedy :). The logic inside the Homey app can’t handle that scenario.  
At the moment that you are crossing the border, the phone app tells the Homey app that it is leaving a fence and/or entering one.

But it is an interesting scenario. It is worth some debugging. Could you give me some logging from the Homey app. First i am interested in the \_location messages. If you are in your town and home, what does the inregions section in that message say. Does it have two entries (home, town)?

---

<div class="post-metadata">

**Author:** ![Gerard](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gerard/32/8846_2.png) [@Gerard](https://community.homey.app/u/Gerard)\
**Post date:** [February 9, 2019, 5:56pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/63 "2019-02-09T17:56:04Z")

</div>

In home (and thus in town):  
20190209-18:26:29 OnMessage called

20190209-18:26:29 received ‘{“batt”:77,“lon”:4.66666666666666,“acc”:65,“p”:100.333333444,“vac”:10,“lat”:52.8888888888,“inregions”:[“home”,“town”],“t”:“p”,“conn”:“w”,“tst”:1546633189,“alt”:-3,"\_type":“location”,“tid”:“GG”}’ on ‘owntracks/gerard/KA9Q77777-ADA6-4006-BC8D-BADCAFEC909’

20190209-18:26:29 We have received a location message

20190209-18:26:29 Set battery percentage for gerard to 77%

20190209-18:26:29 inregions: home,town

20190209-18:26:29 region home

20190209-18:26:29 region town

20190209-18:26:29 User gerard already is in region town

20190209-18:26:29 isAccurate

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 9, 2019, 9:58pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/64 "2019-02-09T21:58:50Z")

</div>

Thanks. That confirms what I thought.  
Supporting.that requires a bit of rethinking of the trigger logic.

Will add a fence inside a fence also to see the trigger behavior.

---

<div class="post-metadata">

**Author:** ![vip](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/vip/32/3873_2.png) [@vip](https://community.homey.app/u/vip)\
**Post date:** [February 10, 2019, 1:25pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/65 "2019-02-10T13:25:32Z")

</div>

How do I set this up from the mobile app 2.0.2?

I can’t find the option to carry out the following.

> When using HTTPS, you have to add users that are allowed to send events to the homey app. To do this, go to the apps settings page and go to the second button (Change users). Add the user name that you want to give access by entering the name in the empty field below the already known users. Press the “+” button to add the user.

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 10, 2019, 2:31pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/66 "2019-02-10T14:31:10Z")

</div>

Doing some major rework on the Location and Presence app. Just managed to get pushing of waypoints working on https connections.  
Pushing of waypoints means that you can send all known geofences from the Homey app to a known phone.

That was already possible for MQTT users, but the internal rework makes it possible to store messages to https connected phones. Once a location change comes in from that phone, the geofences are send inside the https response.

---

<div class="post-metadata">

**Author:** ![scanno](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/scanno/32/8358_2.png) [@scanno](https://community.homey.app/u/scanno)\
**Post date:** [February 10, 2019, 3:20pm UTC](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126/67 "2019-02-10T15:20:09Z")

</div>

In the Athom Homey app, go to the App section, choose Location and Presence. In that screen press Configure App.

Then you will see the Homey Location and Presence settings screen. At the end of the settings screen, select the button/tab users. There you can add the new user.

[Previous page](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126.md?page=2)

[Next page](https://community.homey.app/t/app-pro-location-and-presence-owntracks/5126.md?page=4)
