Created
November 21, 2023 19:07
-
-
Save virnik0/cf858002d90521e984e3bb3112007e74 to your computer and use it in GitHub Desktop.
Backyard Irrigation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias: Backyard Irrigation | |
description: Backyard Grass Irrigation automation | |
trigger: | |
- platform: time | |
at: "06:15" | |
id: "1" | |
- platform: time | |
at: "14:15" | |
id: "2" | |
- platform: time | |
at: "21:40" | |
id: "3" | |
- platform: event | |
event_type: timer.finished | |
event_data: | |
entity_id: timer.backyard_irrigation | |
id: "4" | |
- platform: state | |
entity_id: | |
- input_boolean.backyard_irrigation_toggle | |
to: "on" | |
id: "5" | |
- platform: state | |
entity_id: | |
- input_boolean.backyard_irrigation_toggle | |
to: "off" | |
id: "6" | |
- platform: time | |
at: "14:10" | |
id: "7" | |
- platform: time | |
at: "21:35" | |
id: "8" | |
condition: [] | |
action: | |
- choose: | |
- conditions: | |
- "{{ trigger.id == '1' }}" | |
- condition: time | |
after: "06:00:00" | |
before: "22:00:00" | |
- condition: not | |
conditions: | |
- condition: state | |
entity_id: weather.forecast_home_lan | |
state: | |
- rainy | |
- pouring | |
- lightning-rainy | |
- snowy-rainy | |
- snowy | |
sequence: | |
- service: input_boolean.turn_on | |
data: {} | |
target: | |
entity_id: input_boolean.backyard_irrigation_toggle | |
- service: timer.start | |
target: | |
entity_id: timer.backyard_irrigation | |
data: | |
duration: "00:05:00" | |
- service: number.set_value | |
data: | |
value: "300" | |
target: | |
entity_id: number.backyard_countdown | |
- service: switch.turn_on | |
data: {} | |
target: | |
entity_id: switch.backyard_switch | |
- conditions: | |
- "{{ trigger.id == '2' }}" | |
- condition: time | |
after: "06:00:00" | |
before: "22:00:00" | |
- condition: not | |
conditions: | |
- condition: state | |
entity_id: weather.forecast_home_lan | |
state: | |
- rainy | |
- pouring | |
- lightning-rainy | |
- snowy-rainy | |
- snowy | |
sequence: | |
- service: input_boolean.turn_on | |
data: {} | |
target: | |
entity_id: input_boolean.backyard_irrigation_toggle | |
- service: timer.start | |
target: | |
entity_id: timer.backyard_irrigation | |
data: | |
duration: "00:02:00" | |
- service: number.set_value | |
data: | |
value: "120" | |
target: | |
entity_id: number.backyard_countdown | |
- service: switch.turn_on | |
data: {} | |
target: | |
entity_id: switch.backyard_switch | |
- service: notify.mobile_app_charming | |
data_template: | |
title: Backyard Watering starts! | |
message: Backyard Watering just started! | |
data: | |
ttl: 0 | |
priority: high | |
- service: notify.mobile_app_queen | |
data_template: | |
title: Backyard Watering starts! | |
message: Backyard Watering just started! | |
data: | |
ttl: 0 | |
priority: high | |
- conditions: | |
- "{{ trigger.id == '3' }}" | |
- condition: time | |
after: "06:00:00" | |
before: "22:00:00" | |
- condition: not | |
conditions: | |
- condition: state | |
entity_id: weather.forecast_home_lan | |
state: | |
- rainy | |
- pouring | |
- lightning-rainy | |
- snowy-rainy | |
- snowy | |
sequence: | |
- service: input_boolean.turn_on | |
data: {} | |
target: | |
entity_id: input_boolean.backyard_irrigation_toggle | |
- service: timer.start | |
target: | |
entity_id: timer.backyard_irrigation | |
data: | |
duration: "00:05:00" | |
- service: number.set_value | |
data: | |
value: "300" | |
target: | |
entity_id: number.backyard_countdown | |
- service: switch.turn_on | |
data: {} | |
target: | |
entity_id: switch.backyard_switch | |
- service: notify.mobile_app_charming | |
data_template: | |
title: Backyard Watering starts! | |
message: Backyard Watering just started! | |
data: | |
ttl: 0 | |
priority: high | |
- service: notify.mobile_app_queen | |
data_template: | |
title: Backyard Watering starts! | |
message: Backyard Watering just started! | |
data: | |
ttl: 0 | |
priority: high | |
- conditions: | |
- "{{ trigger.id == '4' }}" | |
sequence: | |
- service: input_boolean.turn_off | |
data: {} | |
target: | |
entity_id: input_boolean.backyard_irrigation_toggle | |
- service: switch.turn_off | |
data: {} | |
target: | |
entity_id: switch.backyard_switch | |
- conditions: | |
- "{{ trigger.id == '5' }}" | |
sequence: | |
- service: timer.start | |
target: | |
entity_id: timer.backyard_irrigation | |
data: | |
duration: "00:05:00" | |
- service: number.set_value | |
data: | |
value: "300" | |
target: | |
entity_id: number.backyard_countdown | |
- service: switch.turn_on | |
data: {} | |
target: | |
entity_id: switch.backyard_switch | |
- conditions: | |
- "{{ trigger.id == '6' }}" | |
sequence: | |
- service: timer.cancel | |
target: | |
entity_id: timer.backyard_irrigation | |
data: {} | |
- service: switch.turn_off | |
data: {} | |
target: | |
entity_id: switch.backyard_switch | |
- conditions: | |
- condition: or | |
conditions: | |
- "{{ trigger.id == '7' }}" | |
- "{{ trigger.id == '8' }}" | |
- condition: time | |
after: "06:00:00" | |
before: "22:00:00" | |
- condition: not | |
conditions: | |
- condition: state | |
entity_id: weather.forecast_home_lan | |
state: | |
- rainy | |
- pouring | |
- lightning-rainy | |
- snowy-rainy | |
- snowy | |
sequence: | |
- service: notify.mobile_app_charming | |
data_template: | |
title: Watering of Backyard is about to start! | |
message: Watering of Backyard starts in 5 minutes! | |
data: | |
ttl: 0 | |
priority: high | |
- service: notify.mobile_app_queen | |
data_template: | |
title: Watering of Backyard is about to start! | |
message: Watering of Backyard starts in 5 minutes! | |
data: | |
ttl: 0 | |
priority: high | |
mode: single |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment