2018-01-02 00:00:45 +00:00
|
|
|
###################################
|
|
|
|
## Uses IFTTT to trigger rain delay with rachio
|
|
|
|
###################################
|
|
|
|
|
|
|
|
- alias: Rachio_Rain_Delay
|
|
|
|
hide_entity: True
|
|
|
|
trigger:
|
|
|
|
- platform: numeric_state
|
|
|
|
entity_id:
|
|
|
|
- sensor.dark_sky_precip_intensity_max
|
|
|
|
- sensor.dark_sky_precip_intensity
|
|
|
|
above: 0.5
|
|
|
|
- platform: numeric_state
|
|
|
|
entity_id: sensor.dark_sky_wind_speed
|
|
|
|
above: 20
|
|
|
|
|
2018-04-04 21:06:47 +00:00
|
|
|
condition:
|
|
|
|
- condition: template
|
|
|
|
value_template: >
|
|
|
|
{%- if states.automation.random_house_stats.attributes.last_triggered -%}
|
|
|
|
{{ (as_timestamp(now()) - as_timestamp(states.automation.rachio_rain_delay.attributes.last_triggered)) > 43200 }}
|
|
|
|
{%- else -%}
|
|
|
|
true
|
|
|
|
{%- endif -%}
|
|
|
|
|
2018-01-02 00:00:45 +00:00
|
|
|
action:
|
|
|
|
- service: ifttt.trigger
|
|
|
|
data_template: {"event":"Rachio_Rain_Delay"}
|
|
|
|
|
2018-03-17 04:56:57 +00:00
|
|
|
- service: script.tweet_engine_image
|
2018-01-02 00:00:45 +00:00
|
|
|
data_template:
|
|
|
|
tweet: >
|
|
|
|
{{ [
|
2018-03-17 04:56:57 +00:00
|
|
|
"Looks like Rain, Pausing the @_Rachio for 24 hours. (https://github.com/CCOSTAN/Home-AssistantConfig#landscaping)",
|
2018-01-02 00:00:45 +00:00
|
|
|
"Since it is going to rain tomorrow, I'll pause @_Rachio for 24 hours.",
|
|
|
|
"No reason to water the grass if it's going to rain tomorrow. pausing @_Rachio for 24 hours.",
|
|
|
|
"Mother Nature is watering the grass today so I can pause @_Rachio for 24 hours."
|
|
|
|
] | random + " #SavingWater"}}
|
2018-03-17 04:56:57 +00:00
|
|
|
image: >-
|
|
|
|
{{ [
|
|
|
|
"/config/www/custom_ui/floorplan/images/branding/hat.png",
|
|
|
|
"/config/www/custom_ui/floorplan/images/branding/rain.png",
|
|
|
|
"/config/www/custom_ui/floorplan/images/branding/rain2.png",
|
2018-03-25 01:49:38 +00:00
|
|
|
"/config/www/custom_ui/floorplan/images/branding/rain3.png"
|
2018-03-17 04:56:57 +00:00
|
|
|
] | random }}
|