mirror of
https://github.com/GeorgeSG/sarah.git
synced 2026-11-03 19:28:43 +00:00
Remove binary sensors for presence
This commit is contained in:
@@ -63,7 +63,7 @@ cards:
|
|||||||
cards:
|
cards:
|
||||||
- type: custom:button-card
|
- type: custom:button-card
|
||||||
template: default
|
template: default
|
||||||
entity: binary_sensor.georgi_home
|
entity: input_boolean.georgi_home
|
||||||
tap_action:
|
tap_action:
|
||||||
action: call-service
|
action: call-service
|
||||||
service: input_boolean.toggle
|
service: input_boolean.toggle
|
||||||
|
|||||||
@@ -30,10 +30,10 @@
|
|||||||
cards:
|
cards:
|
||||||
- type: custom:button-card
|
- type: custom:button-card
|
||||||
template: v3_badge
|
template: v3_badge
|
||||||
entity: binary_sensor.georgi_home
|
entity: input_boolean.georgi_home
|
||||||
- type: custom:button-card
|
- type: custom:button-card
|
||||||
template: v3_badge
|
template: v3_badge
|
||||||
entity: binary_sensor.player_2_home
|
entity: input_boolean.player_2_home
|
||||||
|
|
||||||
- type: horizontal-stack
|
- type: horizontal-stack
|
||||||
cards:
|
cards:
|
||||||
|
|||||||
@@ -258,7 +258,7 @@ automation:
|
|||||||
topic: "z2m_deconz/vibration_sensor"
|
topic: "z2m_deconz/vibration_sensor"
|
||||||
condition:
|
condition:
|
||||||
condition: state
|
condition: state
|
||||||
entity_id: binary_sensor.georgi_home
|
entity_id: input_boolean.georgi_home
|
||||||
state: 'off'
|
state: 'off'
|
||||||
action:
|
action:
|
||||||
- service: notify.mobile_app_carbon
|
- service: notify.mobile_app_carbon
|
||||||
|
|||||||
@@ -17,6 +17,10 @@ automation:
|
|||||||
entity_id: device_tracker.iphone_de_yovcheva
|
entity_id: device_tracker.iphone_de_yovcheva
|
||||||
from: "not_home"
|
from: "not_home"
|
||||||
to: "home"
|
to: "home"
|
||||||
|
- platform: state
|
||||||
|
entity_id: input_boolean.player_2_home
|
||||||
|
from: "off"
|
||||||
|
to: "on"
|
||||||
action:
|
action:
|
||||||
- service: automation.turn_off
|
- service: automation.turn_off
|
||||||
entity_id:
|
entity_id:
|
||||||
@@ -38,8 +42,12 @@ automation:
|
|||||||
trigger:
|
trigger:
|
||||||
- platform: state
|
- platform: state
|
||||||
entity_id: device_tracker.iphone_de_yovcheva
|
entity_id: device_tracker.iphone_de_yovcheva
|
||||||
from: "home "
|
from: "home"
|
||||||
to: "not_home"
|
to: "not_home"
|
||||||
|
- platform: state
|
||||||
|
entity_id: input_boolean.player_2_home
|
||||||
|
from: "on"
|
||||||
|
to: "off"
|
||||||
action:
|
action:
|
||||||
- service: automation.turn_on
|
- service: automation.turn_on
|
||||||
entity_id:
|
entity_id:
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ person:
|
|||||||
user_id: !secret georgi_user_id
|
user_id: !secret georgi_user_id
|
||||||
device_trackers:
|
device_trackers:
|
||||||
- device_tracker.carbon
|
- device_tracker.carbon
|
||||||
|
|
||||||
- name: Player 2
|
- name: Player 2
|
||||||
id: !secret player_2_user_id
|
id: !secret player_2_user_id
|
||||||
device_trackers:
|
device_trackers:
|
||||||
@@ -48,24 +49,6 @@ input_boolean:
|
|||||||
binary_sensor:
|
binary_sensor:
|
||||||
- platform: template
|
- platform: template
|
||||||
sensors:
|
sensors:
|
||||||
georgi_home:
|
|
||||||
friendly_name: Georgi
|
|
||||||
device_class: presence
|
|
||||||
value_template: "{{ is_state('input_boolean.georgi_home', 'on') }}"
|
|
||||||
icon_template: >
|
|
||||||
{% if is_state('input_boolean.georgi_home', 'on') %} mdi:account
|
|
||||||
{% else %} mdi:account-off-outline
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
player_2_home:
|
|
||||||
friendly_name: Player 2
|
|
||||||
device_class: presence
|
|
||||||
value_template: "{{ is_state('input_boolean.player_2_home', 'on') }}"
|
|
||||||
icon_template: >
|
|
||||||
{% if is_state('input_boolean.player_2_home', 'on') %} mdi:account
|
|
||||||
{% else %} mdi:account-off-outline
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
someone_home:
|
someone_home:
|
||||||
friendly_name: Someone home
|
friendly_name: Someone home
|
||||||
device_class: presence
|
device_class: presence
|
||||||
|
|||||||
Reference in New Issue
Block a user