Geofencing problem

strong textHi,

I installed the Proximity add on and copied the Automation of SmartHomeJunky to manage my home temperature regarding the presence of my family members.

This works great, or should i say, worked great.
Suddenly it stopped working and after a long search i spotted something weird that i can not explain.

4 persons created in my person tab

And in the proximity add on 3 of them are used to determine who is at home or not to trigger the automation.

So i work with Ingrid, Marc and Tim.
As mentioned, this worked fine showing on the home entity 3 or 0 or between.
A few days ago i noticed that the automation triggers did not work anymore and found out that the presence, when everybody had left the home, still showed 1 instead of 0. So the temperature setpoint did not change.

What i saw now in the details of the Home (‘thuis’ in Dutch) attribute is the name of the 4’th person which is not chosen in the Proximity addon as shown above.


I can’t find any relation from person Nikki to this Proximity Addon and also don’t know why it showed up.

So help is appreciated to solve this problem.
For the moment i changed my presence from 0 to 1 to have the automation working again.

Thanks in advance
Marc

Don’t give us a video we need to watch as homework to help you… post the automation you are using.

You discuss the Proximity integration, but the Thuis/Home entity you show appears to be a zone entity, not any of the sensors produced by the Proximity integration. The state of any zone entity will be the count of defined person entities that are currently in that zone, it has nothing to do with anything you set up in Proximity.

If the issue is that Nikki was not actually in the zone, then you need to figure out why HA thinks she was. Did she leave her phone at home? Is “Allow Login” checked on her person entity configuration and she logged in on a device that is/was at the house?

1 Like

Thanks Didgeridrew for the advice.
A being a HA newby everything is welcome.
Here is the automation you asked for which i copied out of the video of SmartJunky.

alias: TemperatuurAanwezigheid
description: ""
triggers:
  - entity_id:
      - sensor.thuis_nearest_distance
    id: ApproachingThuis
    below: 2000
    trigger: numeric_state
  - entity_id:
      - zone.home
    above: 1
    id: ApproachingThuis
    trigger: numeric_state
  - entity_id:
      - zone.home
    to: "1"
    id: LeavingThuis
    trigger: state
  - entity_id:
      - sensor.thuis_nearest_distance
    above: 3000
    id: LeavingThuis
    trigger: numeric_state
conditions: []
actions:
  - choose:
      - conditions:
          - condition: and
            conditions:
              - condition: trigger
                id:
                  - ApproachingThuis
              - condition: or
                conditions:
                  - condition: state
                    entity_id: sensor.thuis_nearest_direction_of_travel
                    state: towards
                  - condition: state
                    entity_id: sensor.thuis_nearest_direction_of_travel
                    state: arrived
                  - condition: time
                    after: "07:00:00"
                    before: "23:00:00"
                    weekday:
                      - mon
                      - tue
                      - wed
                      - thu
                      - fri
                      - sun
                      - sat
        sequence:
          - metadata: {}
            data:
              temperature: 20.2
            action: climate.set_temperature
            target:
              entity_id: climate.woonkamer
      - conditions:
          - condition: trigger
            id:
              - LeavingThuis
        sequence:
          - metadata: {}
            data:
              temperature: 15.1
            action: climate.set_temperature
            target:
              entity_id: climate.woonkamer
mode: single

As mentioned, this worked fine but now i had to raise the number of presence to 1 instead of 0 because it seems that one ‘person’ stayed at home.

It is your last sentence that is my question. Nikki is not at home or did not leave her phone here.
Also in the the proximity settings show that only Marc, Ingrid and Tim need to be tracked.
I can’t figure out where Nikki comes in the picture.
At this moment she is not connected to the my HA system but she was a few weeks ago while staying at our home when we were on holiday.
Can it be that HA keeps this ‘state’ when she disconnected from my HA? She doesn’t want to be ‘online’ all the time so she only connects when she is here for more than one day to manage lights and heating.
if this is the case, can i ‘sign her off’ without deleting her profile in the HA system? Is there an automation or script that i can use?

Marc

Yes, if there is no device_tracker active to tell the Person integration that she left, her person entity will continue to hold “home” as it’s state.

The best thing to do would be to find a device tracker integration that will do that for you. If she connects to your WiFi when she visits there are numerous router and/or network based integrations available for presence detection.

If none of those will work for you, it is possible to create a “manual” device tracker and control it’s state with the device_tracker.see action.