#Force update geolocation on wifi connection?

1 messages · Page 1 of 1 (latest)

rich merlin
#

Hi all. I have our door lock/alarm system set up to disarm when my wife or I goes into our geo fence. It works as intended but is just a bit slow at times. I have all the permissions and power saving set correctly on the phones. As a work around I set up the following automation. This seemed to alleviate the problem without draining the phone batteries. Any thoughts on a better way to do this or is this solution pretty good? Thanks for any input!

description: ""
triggers:
  - trigger: state
    entity_id:
      - sensor.sm_s928u1_wi_fi_connection
    to:
      - HomeSSID
  - trigger: state
    entity_id:
      - sensor.sm_s928u1_wi_fi_connection_2
    to:
      - HomeSSID
conditions: []
actions:
  - action: notify.mobile_app_kailynn_phone
    metadata: {}
    data:
      message: request_location_update
  - action: notify.mobile_app_kyle_phone
    metadata: {}
    data:
      message: request_location_update
mode: single
daring stump
#

I realise this isn't what you're aiming for but there's a second way to come at this; if you have something inspecting the ARP table for your network, it can see your phones MAC Address arriving on the network and potentially feed into home assistant to do the same thing (*I don't have a working version of this, but I have been toying with working out how to do it this way because honestly, the companion app is great but dear god does it drink battery if it's set to update location regularly)

#

Using the app is more secure, since MAC Spoofing to open a house ..seems a little unrealistic, AND they'd have to have your SSID PSK but ya know, it could be a thing.

rich merlin
#

I was wondering the same. I have a Firewalla and if I could get it to report the device being there or even just have Home Assistant ping the IP and do a DHCP reservation. Also had the same thought on the geolocation with the app being more secure but the chances of anyone attacking the other way is very very small. Appreciate the ideas and discussion. Great minds. 🙂

grim pier
#

why not just use the wifi connection sensor state change as a condition? its always going to be faster tahn GPS as it updates instantly. location updates can always be delayed from Google

rich merlin
#

I guess I trusted the geolocation more than the SSID name connection? That way if someone has a SSID named the same it doesn't unlock the house if we jump on it. Almost belt and suspenders style this way? Idk maybe the BSSID would be a safer bet then.

misty peak
#

I am looking at the bayesian integration, so I can look at a multitude of factors to determine whether someone is home or not. Zone, SSID, Time, Presence in the home, etc.

steady stone
#

I also found geofenced location updates are too slow for "On Arrival / Departure" automations. Instead of using phone sensors, router integrations usually provide device trackers that indicate whether a device is home/connected or not. You can add the device tracker to your person, which will update your location as described here.
https://www.home-assistant.io/integrations/person/

Home Assistant

Instructions on how to set up people tracking within Home Assistant.

rich merlin
#

This method requires an HA integration for your router right? Sadly there's no integration for Firewalla at the moment. 🙁