From 6c9b0bc053afd61a7df31fead69b6191863a6ec9 Mon Sep 17 00:00:00 2001 From: thomas Date: Fri, 29 Aug 2025 14:37:26 +0000 Subject: [PATCH] blueprints/automation/motion-light.yaml aktualisiert --- blueprints/automation/motion-light.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/blueprints/automation/motion-light.yaml b/blueprints/automation/motion-light.yaml index 0b0a1bf..1b3113c 100644 --- a/blueprints/automation/motion-light.yaml +++ b/blueprints/automation/motion-light.yaml @@ -57,11 +57,13 @@ condition: condition: template value_template: > {% if lux_entity %} - {{ states(lux_entity) | float < lux_threshold }} + {% set lux_value = states(lux_entity) | float(0) %} + {{ lux_value < lux_threshold }} {% else %} true {% endif %} + action: - alias: "Turn on the light with calculated brightness" service: light.turn_on