Edited master bedroom fan script to be a little cleaner

This commit is contained in:
2022-05-10 17:18:45 -04:00
parent 8cd495d37f
commit da2d974e0a

View File

@@ -478,17 +478,17 @@
id: master-bedroom-wakeup id: master-bedroom-wakeup
condition: [] condition: []
action: action:
- if:
- condition: trigger
id: master-bedroom-cooling
then:
- choose: - choose:
- conditions: - conditions:
- condition: trigger
id: master-bedroom-cooling
sequence:
- if:
- condition: numeric_state - condition: numeric_state
entity_id: sensor.current_forecast entity_id: sensor.current_forecast
attribute: overnight_low attribute: overnight_low
above: '40' above: '40'
sequence: then:
- service: fan.turn_on - service: fan.turn_on
data: {} data: {}
target: target:
@@ -504,7 +504,7 @@
title: Fan Schedule Activated title: Fan Schedule Activated
message: Master bedroom fan has been activated, as scheduled based on message: Master bedroom fan has been activated, as scheduled based on
tonight's forecast low tonight's forecast low
default: else:
- parallel: - parallel:
- service: script.text_notify_tony - service: script.text_notify_tony
data: data:
@@ -514,6 +514,21 @@
data: data:
title: Fan Schedule Skipped title: Fan Schedule Skipped
message: Too cold outside, fan not activated message: Too cold outside, fan not activated
- conditions:
- condition: trigger
id: master-bedroom-wakeup
sequence:
- service: fan.turn_off
data: {}
target:
entity_id: fan.master_bedroom_fan_socket_1
default:
- service: script.text_notify_tony
data:
title: Master Bedroom Info
message: '"Today''s wakeup time is set to {{ states(''input_datetime.master_bedroom_wakeup'')
}} and tonight''s cooling is set to start at {{ states(''input_datetime.master_bedroom_cooling'')
}}"'
- if: - if:
- condition: trigger - condition: trigger
id: master-bedroom-wakeup id: master-bedroom-wakeup