Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 105971

First sensor attempt fail

$
0
0

Due to major problems with HA and presence awareness on my Pixel 6 after Android 13 I have decided to use my phones wifi connection to determine if I am home or not and am almost there but not quite.

I added a binary sensor to my configuration.yaml to show either “home” or “not home” so I can create automations based on that but something is not right. The state of the sensor always shows “off” even though the state of the pixel 6 wifi connection is correct.

I have no idea what I am doing wrong and holping someone can asssit me.

Here is what is in my config:

binary_sensor:
  - platform: template
    sensors:
      roberts_pixel_6_home:
        friendly_name: 'Roberts Pixel 6 Home (SSID = Maximilian)'
        device_class: "presence"
        value_template: >-
          {% if states('sensor.pixel_6_wifi_connection') == "Maximilian" %}
          home
          {% else %}
          not_home

I was expecting the value for roberts_pixel_6_home to either show home or not home but it justs shows off

Thanks

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 105971

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>