Been using Hassio in two homes now for almost a year. I’ve been able to implement everything I need, including a custom built monitor that tells me how much heating propane is in my tanks outside. The only thing that I just can’t get working reliably is basic presence detection. I don’t need it to be instant or accurate to the point where it knows whether I’m in the house or not, within a mile of it is fine, and I don’t want to deal with the wifi/bluetooth options.
The webhook geofence options would do the trick- I’ve been using GeoFency, except that the cellular signal at both the homes I use HA at is very poor. So very often, almost half the time, when entering or exiting the geofence, our phones notify us but because the signal is poor the webhook notifications fail. I’ve tried changing the geofence to a lot of different ranges, but none of them have been reliable in either location. All I really need would be for the notification to be held until a cellular or wifi signal is established. Geofency doesn’t seem to have an option for this.
I realize that such a feature would probably need to be implemented as a retry-webhook-until-it-doesn’t-fail hack (as opposed to an IOS automation that triggers the action when data access becomes available) but it would definitely still work for those of us in spotty coverage areas. Anyone know if there is another app that will do this- or if it’s possible to implement this hack myself somehow?
The problem I have with wifi is the phones going to sleep or dead battery and not responding to pings, giving false negatives.
One problem I have with bluetooth is range- in both locations, the signal will go in and out too often to be used for presence detection, just moving about the house. I know there are algorithms that can be applied to predict probability of being present, but even those can give false readings and make things too complicated.
The geofence would work simplest and best for my use case, if there was just a way to persist the web hook until it goes through.
For Bluetooth use monitor, which allows you to do distributed Bluetooth detection.
Overall, use door sensors to determine if it’s possible to have left. I have a somewhat complex set of logic that does that. If an entry/exit door didn’t open and close in the 5 minutes before a tracker shows away, then that person clearly can’t be away. I use 5 minutes because that allows for folks to stand by the front door (still in range of Bluetooth and WiFi) having a chat.
You can also combine different sensors to avoid the problem of the phone’s WiFi going to sleep. Use the state of the group of the sensors, not an individual sensor.
That at least gives you some options while you wait for the phone company to improve the signal
I’m not sure, but I believe it uses the sleep to its advantage.
When you connect to a wifi it updates the wifi SSID.
Then when the phone goes to sleep, it can’t change that.
If the wifi disconnects then the phone must wake up to switch to cellular and therefor the app updates the wifi SSID to unknown (or whatever it is…)
Almost a month ago I decided to invest the time into setting up communicating mqtt brokers in both locations to use with Owntracks. The overwhelming majority of time was spent trying to secure them with TLS. It was confounding, but I could only get a successful handshake working for one of them even though both locations had identical versions of the OS and software. I finally gave up and just used user / pw authentication on that one.
But the time spent on that learning curve definitely paid off. For a month of moving between the two locations, as well as to other zones I created, Owntracks / MQTT has been surprisingly accurate in updating both my and my wife’s locations in both locations (the broker in one house publishes location updates to the other). Sometimes there’s 2-10 minute lag when one of us arrives at one of the houses before not_home changes to home, but I don’t mind at all that I get a resulting false alert once in a while; it’s good to know on a periodic basis that my alarms are working.