Advertisement
Einstine1984

open gate

Feb 19th, 2024
35
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.21 KB | None | 0 0
  1. alias: Open Gate While
  2. description: ""
  3. trigger:
  4. - platform: zone
  5. entity_id: person.voskov
  6. zone: zone.home
  7. event: enter
  8. - platform: zone
  9. entity_id: person.wife
  10. zone: zone.home
  11. event: enter
  12. - platform: state
  13. entity_id:
  14. - binary_sensor.me_in_car
  15. - binary_sensor.wife_in_car
  16. to: "on"
  17. condition: []
  18. action:
  19. - repeat:
  20. while:
  21. - condition: or
  22. conditions:
  23. - condition: and
  24. conditions:
  25. - condition: zone
  26. entity_id: person.wife
  27. zone: zone.home
  28. - condition: state
  29. entity_id: binary_sensor.wife_in_car
  30. state: "on"
  31. - condition: and
  32. conditions:
  33. - condition: state
  34. entity_id: binary_sensor.me_in_car
  35. state: "on"
  36. - condition: zone
  37. entity_id: person.voskov
  38. zone: zone.home
  39. sequence:
  40. - service: script.open_gate
  41. data: {}
  42. - delay:
  43. hours: 0
  44. minutes: 0
  45. seconds: 5
  46. milliseconds: 0
  47. mode: single
  48.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement