WIP condizioni per sensore finestra NOK
This commit is contained in:
6
.gitignore
vendored
6
.gitignore
vendored
@@ -2,4 +2,8 @@ custom_components/*
|
|||||||
www/*
|
www/*
|
||||||
image/*
|
image/*
|
||||||
themes/*
|
themes/*
|
||||||
./.storage/#
|
.storage/*
|
||||||
|
.storage/auth
|
||||||
|
.storage/core.entity_registry
|
||||||
|
.storage/core.restore_state
|
||||||
|
.storage/repairs.issue_registry
|
||||||
|
|||||||
141
automations.yaml
141
automations.yaml
@@ -1,46 +1,48 @@
|
|||||||
- id: '1709331511622'
|
- id: "1709331511622"
|
||||||
alias: BagnoPT-heat_save
|
alias: BagnoPT-heat_save
|
||||||
description: When someone leaves the window open set heat temperature to low value
|
description:
|
||||||
|
When someone leaves the window open set heat temperature to low value
|
||||||
to save power
|
to save power
|
||||||
triggers:
|
triggers:
|
||||||
- type: opened
|
- type: opened
|
||||||
device_id: f93100fe27b6e5bbb01435d9c7c62c39
|
device_id: f93100fe27b6e5bbb01435d9c7c62c39
|
||||||
entity_id: e9b204a2e6a6c7c7c26ecb7099d87a11
|
entity_id: e9b204a2e6a6c7c7c26ecb7099d87a11
|
||||||
domain: binary_sensor
|
domain: binary_sensor
|
||||||
trigger: device
|
trigger: device
|
||||||
conditions:
|
conditions:
|
||||||
- condition: numeric_state
|
- condition: numeric_state
|
||||||
entity_id: sensor.esterno_temperature
|
entity_id: sensor.esterno_temperature
|
||||||
below: 18
|
below: 18
|
||||||
actions:
|
actions:
|
||||||
- device_id: 7743d6b58e5c464426e4b53416a74c7a
|
- device_id: 7743d6b58e5c464426e4b53416a74c7a
|
||||||
domain: climate
|
domain: climate
|
||||||
entity_id: d23578d0c01a087c7c2247fa8fab1113
|
entity_id: d23578d0c01a087c7c2247fa8fab1113
|
||||||
type: set_hvac_mode
|
type: set_hvac_mode
|
||||||
hvac_mode: 'off'
|
hvac_mode: "off"
|
||||||
mode: single
|
mode: single
|
||||||
- id: '1709332450679'
|
- id: "1709332450679"
|
||||||
alias: Bagno-PT-restart_heating
|
alias: Bagno-PT-restart_heating
|
||||||
description: When Finestra-Bagno-PT and window is closed and external temperature
|
description:
|
||||||
|
When Finestra-Bagno-PT and window is closed and external temperature
|
||||||
is below 18 set valvola termosifone to Auto
|
is below 18 set valvola termosifone to Auto
|
||||||
triggers:
|
triggers:
|
||||||
- type: not_opened
|
- type: not_opened
|
||||||
trigger: device
|
trigger: device
|
||||||
device_id: f93100fe27b6e5bbb01435d9c7c62c39
|
device_id: f93100fe27b6e5bbb01435d9c7c62c39
|
||||||
entity_id: e9b204a2e6a6c7c7c26ecb7099d87a11
|
entity_id: e9b204a2e6a6c7c7c26ecb7099d87a11
|
||||||
domain: binary_sensor
|
domain: binary_sensor
|
||||||
condition:
|
condition:
|
||||||
- condition: numeric_state
|
- condition: numeric_state
|
||||||
entity_id: sensor.esterno_temperature
|
entity_id: sensor.esterno_temperature
|
||||||
below: 18
|
below: 18
|
||||||
action:
|
action:
|
||||||
- device_id: 7743d6b58e5c464426e4b53416a74c7a
|
- device_id: 7743d6b58e5c464426e4b53416a74c7a
|
||||||
domain: climate
|
domain: climate
|
||||||
entity_id: d23578d0c01a087c7c2247fa8fab1113
|
entity_id: d23578d0c01a087c7c2247fa8fab1113
|
||||||
type: set_hvac_mode
|
type: set_hvac_mode
|
||||||
hvac_mode: heat
|
hvac_mode: heat
|
||||||
mode: single
|
mode: single
|
||||||
- id: '1709401667410'
|
- id: "1709401667410"
|
||||||
alias: Luce Scala Taverna (sensore alto)
|
alias: Luce Scala Taverna (sensore alto)
|
||||||
description: Attiva Luce Scala Taverna su presenza
|
description: Attiva Luce Scala Taverna su presenza
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
@@ -50,7 +52,7 @@
|
|||||||
light_target:
|
light_target:
|
||||||
device_id: 226779fb30bd68c5a2784ccd762d90e9
|
device_id: 226779fb30bd68c5a2784ccd762d90e9
|
||||||
no_motion_wait: 20
|
no_motion_wait: 20
|
||||||
- id: '1728486287191'
|
- id: "1728486287191"
|
||||||
alias: Luce Scala Taverna (sensore basso)
|
alias: Luce Scala Taverna (sensore basso)
|
||||||
description: Attiva Luce Scala Taverna su presenza
|
description: Attiva Luce Scala Taverna su presenza
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
@@ -60,7 +62,7 @@
|
|||||||
light_target:
|
light_target:
|
||||||
device_id: 226779fb30bd68c5a2784ccd762d90e9
|
device_id: 226779fb30bd68c5a2784ccd762d90e9
|
||||||
no_motion_wait: 20
|
no_motion_wait: 20
|
||||||
- id: '1728594248560'
|
- id: "1728594248560"
|
||||||
alias: Luce Scala Mansarda (sensore alto)
|
alias: Luce Scala Mansarda (sensore alto)
|
||||||
description: Attiva Luce Scala Mansarda su presenza
|
description: Attiva Luce Scala Mansarda su presenza
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
@@ -70,7 +72,7 @@
|
|||||||
light_target:
|
light_target:
|
||||||
device_id: 702137a6f2c17b89fdb0598f7003743c
|
device_id: 702137a6f2c17b89fdb0598f7003743c
|
||||||
no_motion_wait: 20
|
no_motion_wait: 20
|
||||||
- id: '1728594117428'
|
- id: "1728594117428"
|
||||||
alias: Luce Scala Mansarda (sensore basso)
|
alias: Luce Scala Mansarda (sensore basso)
|
||||||
description: Attiva Luce Scala Mansarda su presenza
|
description: Attiva Luce Scala Mansarda su presenza
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
@@ -80,7 +82,7 @@
|
|||||||
light_target:
|
light_target:
|
||||||
device_id: 702137a6f2c17b89fdb0598f7003743c
|
device_id: 702137a6f2c17b89fdb0598f7003743c
|
||||||
no_motion_wait: 20
|
no_motion_wait: 20
|
||||||
- id: '1729875991469'
|
- id: "1729875991469"
|
||||||
alias: BagnoOvest-save-energy
|
alias: BagnoOvest-save-energy
|
||||||
description: Thermostat will close upon window open
|
description: Thermostat will close upon window open
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
@@ -88,21 +90,80 @@
|
|||||||
input:
|
input:
|
||||||
window_sensor: binary_sensor.bagnoovest_finestra_contact
|
window_sensor: binary_sensor.bagnoovest_finestra_contact
|
||||||
climate_target: climate.bagnoovest_termosifone
|
climate_target: climate.bagnoovest_termosifone
|
||||||
- id: '1729887529602'
|
- id: "1729887529602"
|
||||||
alias: BagnoPT-save-energy
|
alias: BagnoPT-save-energy
|
||||||
description: ''
|
description: ""
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
path: homeassistant/heat_save.yaml
|
path: homeassistant/heat_save.yaml
|
||||||
input:
|
input:
|
||||||
window_sensor: binary_sensor.bagnopt_finestra_contact
|
window_sensor: binary_sensor.bagnopt_finestra_contact
|
||||||
climate_target: climate.bagnopt_termosifone
|
climate_target: climate.bagnopt_termosifone
|
||||||
ext_temp_limit: 17
|
ext_temp_limit: 17
|
||||||
- id: '1729887632269'
|
- id: "1729887632269"
|
||||||
alias: SoggiornoPT-save-energy
|
alias: SoggiornoPT-save-energy
|
||||||
description: ''
|
description: ""
|
||||||
use_blueprint:
|
use_blueprint:
|
||||||
path: homeassistant/heat_save.yaml
|
path: homeassistant/heat_save.yaml
|
||||||
input:
|
input:
|
||||||
window_sensor: binary_sensor.soggiornopt_finestrasud_contact
|
window_sensor: binary_sensor.salottopt_finestra_contact
|
||||||
climate_target: climate.soggiornopt_termosifonesud
|
climate_target: climate.soggiornopt_termosifonesud
|
||||||
ext_temp_limit: 17
|
ext_temp_limit: 17
|
||||||
|
- id: "1729899451580"
|
||||||
|
alias: test-switch
|
||||||
|
description: ""
|
||||||
|
triggers:
|
||||||
|
- type: opened
|
||||||
|
device_id: d9e47be4d9369f77ee2c07273324bc46
|
||||||
|
entity_id: ebae111d5248a4a919571b66f79824d3
|
||||||
|
domain: binary_sensor
|
||||||
|
trigger: device
|
||||||
|
|
||||||
|
actions:
|
||||||
|
- choose:
|
||||||
|
# if finestra is open
|
||||||
|
- conditions: >
|
||||||
|
{{ is_state('binary_sensor.salottopt_finestra_contact', 'off ') }}
|
||||||
|
# - condition: state
|
||||||
|
# entity_id: binary_sensor.salottopt_finestra_contact
|
||||||
|
# state: "on"
|
||||||
|
# for:
|
||||||
|
# hours: 0
|
||||||
|
# minutes: 0
|
||||||
|
# seconds: 3
|
||||||
|
sequence:
|
||||||
|
- action: switch.turn_off
|
||||||
|
metadata: {}
|
||||||
|
data: {}
|
||||||
|
target:
|
||||||
|
device_id: 62352ecf274ff68e3ddfbc979406d49d
|
||||||
|
- action: notify.mobile_app_ttrabatt_iphone15pro
|
||||||
|
metadata: {}
|
||||||
|
data:
|
||||||
|
message: Home Assistant DEBUG
|
||||||
|
title: Dovrebbe essere finestra aperta
|
||||||
|
# if finestra is closed
|
||||||
|
- conditions: >
|
||||||
|
{{ is_state('binary_sensor.salottopt_finestra_contact', 'on ') }}
|
||||||
|
# - condition: state
|
||||||
|
# entity_id: binary_sensor.salottopt_finestra_contact
|
||||||
|
# state: "off"
|
||||||
|
sequence:
|
||||||
|
- action: switch.turn_on
|
||||||
|
metadata: {}
|
||||||
|
data: {}
|
||||||
|
target:
|
||||||
|
device_id: 62352ecf274ff68e3ddfbc979406d49d
|
||||||
|
- action: notify.mobile_app_ttrabatt_iphone15pro
|
||||||
|
metadata: {}
|
||||||
|
data:
|
||||||
|
message: Home Assistant DEBUG
|
||||||
|
title: Dovrebbe essere finestra chiusa
|
||||||
|
default:
|
||||||
|
- action: notify.mobile_app_ttrabatt_iphone15pro
|
||||||
|
metadata: {}
|
||||||
|
data:
|
||||||
|
title: HA script error
|
||||||
|
message: >
|
||||||
|
le condizioni non vanno cazzo: state: {{ states('binary_sensor.salottopt_finestra_contact') }}
|
||||||
|
|
||||||
|
mode: single
|
||||||
|
|||||||
@@ -41,26 +41,79 @@ conditions:
|
|||||||
below: !input ext_temp_limit
|
below: !input ext_temp_limit
|
||||||
|
|
||||||
actions:
|
actions:
|
||||||
- if:
|
- choose:
|
||||||
- condition: state
|
- conditions:
|
||||||
entity_id: !input window_sensor
|
- condition: state
|
||||||
state: "open"
|
entity_id: !input window_sensor
|
||||||
for:
|
state: "Open"
|
||||||
hours: 0
|
sequence:
|
||||||
minutes: 0
|
- action: climate.set_hvac_mode
|
||||||
seconds: 10
|
metadata: {}
|
||||||
then:
|
data:
|
||||||
- action: climate.set_hvac_mode
|
hvac_mode: "off"
|
||||||
|
target:
|
||||||
|
entity_id: !input climate_target
|
||||||
|
- action: switch.turn_on
|
||||||
|
metadata: {}
|
||||||
|
data: {}
|
||||||
|
target:
|
||||||
|
device_id: 62352ecf274ff68e3ddfbc979406d49d
|
||||||
|
- action: notify.mobile_app_ttrabatt_iphone15pro
|
||||||
|
metadata: {}
|
||||||
|
data:
|
||||||
|
message: Home Assistant DEBUG
|
||||||
|
title: Dovrebbe essere finestra aperta
|
||||||
|
|
||||||
|
- conditions:
|
||||||
|
- condition: state
|
||||||
|
entity_id: !input window_sensor
|
||||||
|
state: "Closed"
|
||||||
|
sequence:
|
||||||
|
- action: climate.set_hvac_mode
|
||||||
|
metadata: {}
|
||||||
|
data:
|
||||||
|
hvac_mode: "heat"
|
||||||
|
target:
|
||||||
|
entity_id: !input climate_target
|
||||||
|
- action: switch.turn_off
|
||||||
|
metadata: {}
|
||||||
|
data: {}
|
||||||
|
target:
|
||||||
|
device_id: 62352ecf274ff68e3ddfbc979406d49d
|
||||||
|
- action: notify.mobile_app_ttrabatt_iphone15pro
|
||||||
|
metadata: {}
|
||||||
|
data:
|
||||||
|
message: Home Assistant DEBUG
|
||||||
|
title: Dovrebbe essere finestra chiusa
|
||||||
|
|
||||||
|
default:
|
||||||
|
- action: notify.mobile_app_ttrabatt_iphone15pro
|
||||||
metadata: {}
|
metadata: {}
|
||||||
data:
|
data:
|
||||||
hvac_mode: "off"
|
title: HA script error
|
||||||
target:
|
message: >
|
||||||
entity_id: !input climate_target
|
le condizioni non vanno cazzo: state: {{ states('binary_sensor.salottopt_finestra_contact') }}
|
||||||
else:
|
|
||||||
- action: climate.set_hvac_mode
|
# - if:
|
||||||
metadata: {}
|
# - condition: state
|
||||||
data:
|
# entity_id: !input window_sensor
|
||||||
hvac_mode: heat
|
# state: "true"
|
||||||
target:
|
# for:
|
||||||
entity_id: !input climate_target
|
# hours: 0
|
||||||
mode: single
|
# minutes: 0
|
||||||
|
# seconds: 10
|
||||||
|
# then:
|
||||||
|
# - action: climate.set_hvac_mode
|
||||||
|
# metadata: {}
|
||||||
|
# data:
|
||||||
|
# hvac_mode: "off"
|
||||||
|
# target:
|
||||||
|
# entity_id: !input climate_target
|
||||||
|
# else:
|
||||||
|
# - action: climate.set_hvac_mode
|
||||||
|
# metadata: {}
|
||||||
|
# data:
|
||||||
|
# hvac_mode: heat
|
||||||
|
# target:
|
||||||
|
# entity_id: !input climate_target
|
||||||
|
# mode: single
|
||||||
|
|||||||
@@ -23,7 +23,11 @@ binary_sensor: !include binary_sensors.yaml
|
|||||||
recorder:
|
recorder:
|
||||||
db_url: !secret mariadb_url
|
db_url: !secret mariadb_url
|
||||||
|
|
||||||
# influxdb: !include influxdb_feed.yaml
|
# log INFO level messages
|
||||||
|
logger:
|
||||||
|
default: info
|
||||||
|
|
||||||
|
# influxdb: !include influxdb_feed.yaml
|
||||||
|
|
||||||
# Zigbee Network Map
|
# Zigbee Network Map
|
||||||
mqtt:
|
mqtt:
|
||||||
|
|||||||
Reference in New Issue
Block a user