How to use location tracking only to detect HOME /AWAY states, without knowing the exact location?

I would like to use Home Assistant official Android app location tracking feature to detect HOME /AWAY states. But there is a problem: some family members want privacy. Is there a way to use location tracker to detect if a person is at home, without knowing her exact location?

I thought that the “zone based tracking” setting does what I need, but it seems it doesn’t: after activating it, I still can see person’s location in the map.

2 Likes

You could detect if the person’s phone was connected to your local wifi network.

You are right. But it’s less reliable, because sometimes we deactivate WiFi, and it’s constantly making queries to the router.

BLE beacon?

I prefer the WiFi solution, it’s easier. Just asking if it’s possible with Android app location tracking. If it’s not, then I’ll use WiFi.

The app is GPS based, though you could try denying it access to the GPS and see if it works :man_shrugging:

Otherwise, use Bluetooth. I combine Bluetooth, WiFi, a door sensor, and a little logic to do reliable home/away tracking.

1 Like

Thank you for all your answers!

Could you share your logic? It is interesting to see and maybe implement

You’ll probably regret asking, but here it is :stuck_out_tongue:

The writeup there covers everything (at least I think it does), including all the integrations, devices, software, etc.

1 Like

Oh, thats a lot of stuff! :slight_smile:

I’m planning to buy a Orange pi zero plus and dedicate it to presence detection. I’m gonna make a program ( mostly script ) that check for the device on the network and if the device is off for like 10 minutes it send the status to home assistant ( same for bluetooth ) I would like to make a little web interface too for changing mac and bluetooth Mac dress if I change my phone. then on home assistant I will make rule that said if BOTH wifi and bluetooth are of I’m not there but as soon as wifi or bluetooth is on I’m there

Sounds like a group :wink:

Yes exactly ! AHAH

You could of course just group a WiFi and Bluetooth tracker, then use a binary sensor template with a delay in the off of 10 minutes.

Hoping all the knowledge here and effort will be added in an easy to use package in 6 months :stuck_out_tongue:

A package would require editing to update the various trackers. We’re talking about a single group, and a single binary sensor. That’s “somewhat” overkill for a package :wink:

group:
  human_tom:
    name: Tom
    entities:
    - device_tracker.tom_bluetooth
    - device_tracker.tom_wifi

and

binary_sensor:
  - platform: template
    sensors:
      tom_home:
        friendly_name: "Tom is home"
        value_template: >-
          {{ is_state('group.human_tom', 'home') }}
        delay_off: '00:05:00'

Package that logic up if it suits you.

I mean the proccess of setting up the bluetooth beacon,

Will look into it more when I move out in 6 months time but as things move so quickly we could be looking at diffrent method by then

Yeah, I am looking for the same thing, one would think that is how “zone based tracking” should work, but it doesn’t. I want the user (off the app) to have control over their own privacy. Turning off GPS makes tracking work worse, and I don’t see why the app cant just send the away/home-status without the exact position.

I opened this as a bug for the companion app, as this behavior seems both misleading and way too privacy invading. Give the issue a thumbs up on GitHub if you agree: