adds humidity

This commit is contained in:
2026-06-29 15:08:51 +02:00
parent 3a451a034e
commit 405ffb96cf

View File

@@ -54,6 +54,30 @@ blueprint:
min: 0
max: 100
unit_of_measurement: lx
humidity_section:
name: "Humidity"
#icon: mdi:window-shutter-cog
description: Configure humidity override (optional)
input:
humidity_sensors:
name: Humidity sensors
description: The humidity sensor for shower detection.
default: []
selector:
entity:
multiple: true
filter:
domain: sensor
device_class: humidity
humidity_threshold:
name: Humidity threshold
description: Humidity above this threshold will activate the "on" scene.
default: 75
selector:
number:
min: 50
max: 90
unit_of_measurement: '%'
scene_section:
name: "Scene configuration"
#icon: mdi:window-shutter-cog
@@ -97,13 +121,14 @@ max_exceeded: silent
# Everything defined here can be used inside Jinja code in triggers
################################################################################
trigger_variables:
motion_sensors: !input motion_sensors
humidity_sensors: !input humidity_sensors
humidity_threshold: !input humidity_threshold
################################################################################
# VARIABLES
################################################################################
variables:
version: "2026.03.2"
version: "2026.06.1"
#blind_entities: "{{ expand(blind) | map(attribute='entity_id') | list }}"
################################################################################
@@ -115,6 +140,14 @@ triggers:
entity_id: !input motion_sensors
from: "off"
to: "on"
- trigger: template
value_template: >
{{ expand(humidity_sensors)
| selectattr('state', 'gt', humidity_threshold) | list | count == 1 }}
#- trigger: numeric_state
# entity_id: !input humidity_sensors
# above: {{ states(humidity_threshold) | float }}
# - trigger: template
# value_template: >
@@ -161,6 +194,7 @@ actions:
entity_id: !input motion_sensors
from: "on"
to: "off"
# "If not restarted because of any motion the light is turned off after the delay"
- alias: "Wait the number of seconds that has been set"
delay: !input no_motion_wait
- alias: "Activate off scene"