blueprints/automation/device-status-energy.yaml aktualisiert

This commit is contained in:
2025-05-12 14:39:09 +00:00
parent 5e4407c812
commit 77f2b5fafb

View File

@@ -1,6 +1,6 @@
blueprint:
name: Device Status Based on Power Consumption
description: A blueprint to track device status using energy consumption with configurable thresholds and delays.
name: Binary Sensor for Device Power Status
description: A template binary sensor that tracks device status based on energy consumption thresholds.
domain: automation
input:
power_sensor:
@@ -19,7 +19,7 @@ blueprint:
max: 100
delay_on:
name: Turn-On Delay (Minutes)
description: Waiting time before changing the status to "Device is running".
description: Waiting time before changing the binary sensor state to "on".
default: 1
selector:
number:
@@ -28,19 +28,18 @@ blueprint:
unit_of_measurement: minutes
delay_off:
name: Turn-Off Delay (Minutes)
description: Waiting time before changing the status to "Device is off".
description: Waiting time before changing the binary sensor state to "off".
default: 3
selector:
number:
min: 0
max: 20
unit_of_measurement: minutes
status_helper:
name: Device Status Helper
description: An input_boolean helper that tracks device status.
binary_sensor_name:
name: Binary Sensor Entity ID
description: The name of the binary sensor entity to be created.
selector:
entity:
domain: input_boolean
text:
mode: restart
trigger:
@@ -50,9 +49,9 @@ trigger:
for:
minutes: !input delay_on
action:
- service: input_boolean.turn_on
- service: homeassistant.update_entity
target:
entity_id: !input status_helper
entity_id: !input binary_sensor_name
- wait_for_trigger:
- platform: numeric_state
@@ -61,6 +60,6 @@ action:
for:
minutes: !input delay_off
- service: input_boolean.turn_off
- service: homeassistant.update_entity
target:
entity_id: !input status_helper
entity_id: !input binary_sensor_name