Add push notifications on start and end with current humidity
This commit is contained in:
parent
e962098ba2
commit
7e0d6193ad
1 changed files with 42 additions and 1 deletions
|
|
@ -5,7 +5,8 @@ blueprint:
|
|||
wenn ein Helfer-Schalter aktiviert wird. Startet nur bei ausreichender
|
||||
Luftfeuchtigkeit und geschlossenen Fenstern/Türen. Bricht ab, sobald
|
||||
ein Fenster oder eine Tür geöffnet wird, und setzt die Klimaanlage
|
||||
danach auf den vorherigen Modus zurück.
|
||||
danach auf den vorherigen Modus zurück. Optional: Push-Benachrichtigung
|
||||
beim Start und Ende mit aktuellem Feuchtigkeitswert.
|
||||
domain: automation
|
||||
input:
|
||||
dehumidify_switch:
|
||||
|
|
@ -66,6 +67,22 @@ blueprint:
|
|||
unit_of_measurement: min
|
||||
mode: slider
|
||||
|
||||
room_name:
|
||||
name: Raumname
|
||||
description: Wird in der Push-Nachricht angezeigt (z. B. Schlafzimmer)
|
||||
default: Raum
|
||||
selector:
|
||||
text:
|
||||
|
||||
notify_target:
|
||||
name: Benachrichtigungsdienst (optional)
|
||||
description: >
|
||||
Notify-Dienst für Push-Nachrichten, z. B. notify.mobile_app_dein_handy.
|
||||
Leer lassen für keine Benachrichtigung.
|
||||
default: ""
|
||||
selector:
|
||||
text:
|
||||
|
||||
variables:
|
||||
dehumidify_switch: !input dehumidify_switch
|
||||
climate_entity: !input climate_entity
|
||||
|
|
@ -73,6 +90,8 @@ variables:
|
|||
humidity_threshold: !input humidity_threshold
|
||||
contact_sensors: !input contact_sensors
|
||||
duration_minutes: !input duration_minutes
|
||||
room_name: !input room_name
|
||||
notify_target: !input notify_target
|
||||
previous_mode: "{{ state_attr(climate_entity, 'hvac_mode') | default(states(climate_entity)) }}"
|
||||
|
||||
trigger:
|
||||
|
|
@ -99,6 +118,17 @@ action:
|
|||
data:
|
||||
hvac_mode: dry
|
||||
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: "{{ notify_target != '' }}"
|
||||
then:
|
||||
- service: "{{ notify_target }}"
|
||||
data:
|
||||
title: "💧 Entfeuchtung gestartet"
|
||||
message: >
|
||||
{{ room_name }}: Klimaanlage läuft im Dry-Modus für {{ duration_minutes }} Minuten.
|
||||
Aktuelle Luftfeuchtigkeit: {{ states(humidity_sensor) | round(1) }} %
|
||||
|
||||
- wait_for_trigger:
|
||||
- platform: template
|
||||
value_template: >
|
||||
|
|
@ -128,6 +158,17 @@ action:
|
|||
data:
|
||||
hvac_mode: "off"
|
||||
|
||||
- if:
|
||||
- condition: template
|
||||
value_template: "{{ notify_target != '' }}"
|
||||
then:
|
||||
- service: "{{ notify_target }}"
|
||||
data:
|
||||
title: "✅ Entfeuchtung beendet"
|
||||
message: >
|
||||
{{ room_name }}: Klimaanlage wurde zurückgesetzt.
|
||||
Aktuelle Luftfeuchtigkeit: {{ states(humidity_sensor) | round(1) }} %
|
||||
|
||||
- service: input_boolean.turn_off
|
||||
target:
|
||||
entity_id: !input dehumidify_switch
|
||||
|
|
|
|||
Loading…
Reference in a new issue