Be able to use an “and trigger” for example if me and my wife are out of our home zone then trigger an automation , if me or my wife are home home then do nothing , only trigger if we are bothe away
Hello Jamie,
I’m sure that can be done. Also having someone or something writing it for you means the second it misbehaves, you will be struggling back to find someone to fix it for you.
The best way to learn is to just try. Run thru the docs on getting started with the automation editor. If you get stuck, come back with what you have done.
Triggers are instantaneous events: there’s no such concept as AND. A trigger would be you or your wife leaving home.
The way to work the automation is to trigger off each of you leaving, then add a condition that checks you are both away.
triggers:
- trigger: state
entity_id:
- person.jamie
- person.wife
from: 'home'
conditions:
- not:
- condition: state
entity_id: person.jamie
state: 'home'
- condition: state
entity_id: person.wife
state: 'home'
actions:
[etc]
That is covered in the next section of an automation after ‘trigger’ called ‘conditions’. In the UI it’s the ‘And if’ section. I use it on most of my automations to keep my house mate happy, if I’m not home the lights do not automatically come on around sunset.
Edit: I type way to freaking slow and over check myself before hitting ‘Post’ .