Having set up HVAC using Versatile Thermostat and Scheduler from HACS, I now want to get Presence working properly.
I think that I understand presence for myself and my family as individuals.
We live in a rural area. The City is several hours away, and we can only travel homewards by passing through our nearby Town.
My idea is that the HVAC should go to low energy mode if no-one will be home soon.
In Zones, I have a zone for Nearly Home and another for Town. My idea is that if any of us is home or moves from Town to Nearly Home then the house should warm itself up.
So I need a few things…
How to represent Anybody Home without listing everyone in each rule?
How to know if anyone is moving towards home rather than away?
This sounds like a common problem. Is there a clever Blueprint that deals with all this neatly?
You could use the Bayesian integration to calculate the probability of someone being home, based on movement, phone locations state of lights etc. It’s surprisingly accurate and will give you a single binary entity.
Interesting, but since I have device tracking for all five people I am going to stick with the zone/movement idea. . . . but the Baynesian approach would be helpful if we are all away and have a house sitter . . . => I need to include an override Heating ON switch for house sitters who are not known otherwise!
The easiest way I’ve found is to put all your family members is a group.This solves two of the three logical conclusions. Group is off then Nobody Home, Group is on then somebody home (possibly everybody).
Next create 3 input_booleans; Everyone Home, Someone Home and Nobody Home. Checking the status of the Group with an automation will allow you to set the value of Someone Home or Nobody Home easily. A second automation where you check for EVERYBODY HOME will complete the logic. 1 Group, 3 helpers and 2 automations. Pretty easy to set up and test and works for any number of family members.
Maybe not the sexiest way to do it but clean and easy and it works.
there is something wrong with my own location - I am reporting as Home.
For testing, I am now using a family member who is reporting as distant.
Proximity looks good but
A) works with devices rather than people
B) has no UI
I’ve set up an !include file for Proximity to live in and registered the one family member to test with.
I now have a single Proximity sensor which has the nearness of the nearest family member’s phone
In HACS / Automation I found Monitor-App for “Andrew’s Monitor Presence Detection System”. I only want to monitor one location (home) so instead, I can use the custom Add-In GitHub - Limych/addon-presence-monitor at v1.0.0 and don’t need AppDaemon.
However, my bluetooth does not currently work, so I’m not looking further at this solution until BLE is available.
In any case, BLE does not help with the “is anyone on their way home?” question - that is better approached using Zones and making sure everyone has the App installed and has the Nabu Casa cloud service configured, so that Geolocation can be used.
Once Bluetooth / BLE is working, it would be good to use BLE to detect guests (non family members) via BLE detection of all standard mobile phone types.