iPhone Geofence not working

Having an issue with my wife's iPhone updating Geo Location via Hubitat app. GeoFence is enabled in app and the GeoFence is setup in app. Under advanced location options in Hubitat app, everything is turned on other than presence while in motion. In iPhone settings, Hubitat is allowed to access Location Always (precise location). It is also has access to cell data, background refresh. The app shows that it is Inside GeoFence and even when I hit Send Geo Event, the mobile app presence sensor still shows away.

@bobbyD might have to field this one... Everything you have going looks correct.

So I logged out, uninstalled the app, re-installed the app and logged back in and it worked! ONCE! :frowning: It hasn't automatically updated since. She can manually hit Send Geo Event and that works now (was not working before), But automatic updates is still not happening. :frowning:

I have exactly the same problem x6 iPhones (across the family). I’ve opened a support ticket with @bobbyD. Was told it has been forwarded to engineering and that I might hear back. Seems confusing, so I asked for clarification, but only crickets so far.

I know it's not the answer you are searching for, but if you have a HomeKit capable device (HomePod/AppleTV) It's possible to setup additional geofencing with an automation.

I use that option at home as my wife never uses the Hubitat app, and it's nice to have a fall back.

May I ask how you use Homekit to do this?

I'd like to know too. Phone presence has been broken for both my wife and I for a few weeks. Annoying too.

  1. You need to connect Hubitat to HomeKit. Use either the MakerAPI or HomeBridge method to achieve this.

  2. Setup a switch for each member of your family you want to monitor, and make sure that switch exist in HomeKit

  3. In the Home app setup an automation using the geofence. If you use the Home App that should be at least 2 automations, per member.

  4. Setup as many Virtual Presence devices as needed on your Hubitat.

  5. In RuleMachine you setup a trigger that watches your switch(es) from HomeKit, and the presence detektors from Hubitat, that switches the virtual presence detektors you created in 4.

These devices can then be used in for example, the mode manager.

The best thing about this, is that you can easily add more presence detektors to the rule in the future. I'm looking for some beacons I might add to this rule.

Does this require you to have an Apple TV, HomePod, or iPad at home? I don’t seem to have the ability to create these automations.

Yes. You need some form of HomeKit base to do automations.

So I kinda got it working using a virtual presence sensor controlled by Alexa, IFTTT, and Hubitat apps. iPhone Hubitat app presence still does not work.

  1. I created a Virtual Presence device using Virtual Switch Universal Device uDTH.
  1. Used the iPhone WiFi Presence Sensor device driver to turn on the Virtual Presence sensor whenever her iPhone connects to the home WiFi. You will need to go into your router and setup a DHCP reservation for the iPhone so that it gets the same IP address every time it connects.

  2. Use IFTTT app on her iPhone to turn on/off her Virtual Presence sensor whenever she enter/leaves the area around our house. I had to create a new IFTTT account for her phone, but you get 3 free apps to create.

  3. Use the Alexa app to create Routines to turn on/off the Virtual Presence sensor based on Location. (Similar to IFTTT)

  4. Use Basic Rules to turn on/off the Virtual Presence sensor whenever the her iPhone presence sensors is present or not present (this never works which is why we need to do all of this stuff in the first place, but figured if the Hubitat iPhone app ever does start working its an extra way of getting timely presence info).

The big problem from what I can see is the iPhone is just killing background apps after a certain time or if too many apps are running in the background. Background apps are battery killers and unless Apple decides that you need it, it will just kill it without caring for the end user (remember when Apple throttled the CPU when the battery was getting old and lost a class action suit). This could be the reason why using the Apple HomeKit works better than others!!!

Android users will have the same kind of problem depending on the manufacturer, Google is working hard so that manufacturers don't kill background apps unless it is user specified to do so, but the big ones like Samsung, LG, etc. are not cooperating very much because having background apps working all the time kills the battery life and they get complaints from users even for non power users.

Except that the IFTTT and Alexa apps work for Geofencing in the background. Hubitat app should also be able to work, but does not.

Don't know about IFTTT for geofencing, but I can assure you that on my iPhone 6S and my wife's iPhone 8 Alexa app does not work for more than a few days before it stops reporting, so unless I open it up every day, it is being killed off in the background. I have tried every thing I could find to keep it up and running but to no avail.

So I just gave up and got a few SmartThings arrival sensors, a part from being battery hungry, they work flawlessly.

My wife's virtual presence sensor is still working correctly. I'm not sure if it is the IFTTT or Alexa app that is working, but it is working. I do know that it is definitely NOT the Hubitat iPhone app that is working.

did you make sure that the correct device id matches on the iphone and in the hubitat device list settings for the mobile device?

Another option people seem to like is Life 360 (free version). That seems fairly reliable

2 Likes

Life360 has been very reliable for my family, on both iOS and Android phones.

1 Like

I'm a new HE owner, and am in the same boat,

My wife's iPhone app never seems to update its presence, I really want to avoid having to get other accounts to solve the problem. I only use presence to enable HSM's away mode, and for thermostat management, so I would like it to work as expected. If there are any tips or tricks that I can try that would be helpful and I would be much appreciated.

Once i disabled the battery optimization mode on my Android phone, its presence has been spot on.

Thanks and Take Care
-Pat

Download the Hubitat app