Advertisement
314ma

open_cover_5m_before_alarm

Aug 19th, 2020
359
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 0.33 KB | None | 0 0
  1. - alias: open_cover_5m_before_alarm
  2.   trigger:
  3.     - platform: template
  4.       value_template: "{{ (state_attr('sensor.mobile_app_next_alarm', 'Time in Milliseconds')/1000 - strptime(states('sensor.date_time'), '%Y-%m-%d, %H:%M') | as_timestamp()) == 5*60 }}"
  5.   action:
  6.     - service: cover.open_cover
  7.       entity_id: cover.bedroom
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement