Status before trigger!

Hi!

I have 4 presence sensors:

  • Me
  • Wife
  • Daughter
  • Someone is home (as long as one of the 3 is present it is present, when last person leaves switch to not present)

I tried a rule that unlock the door when I arrive if it is lock (doesn't matter if someone is home) and start a playlist on my Sonos if nobody home.

The door unlock when I arrive (so the rule starts), but the playlist didn't sart. I then realize that when I arrive, the presence sensor "Someone is home" is switched at the same time (I'm there!), therefore playlist will never start because someone is there.

Is there a way to know what was the status of Someone is home just before?

Of should I have 2 rule:

  • Rule 1: unlock when I arrive
  • Rule 2: Required expression = Someone is home is false to launch my playlist?

Thanks!

c5c07787fa4bce1b41bc9d568292e45a-1724218394

That won't work, because he is home. Condition 'Only trembbben is present' would work. That's probably easier as "Wife, Daughter All Not Present".

Where can I do "check if only trembben is present"? I tried to change the condition but If I choose my prsenece sensor, the only options are present, not present and no selection.

Side note: I use Combined Presence from joelwetzel, so All not present is done within a separate switch :slight_smile:

How about "NOT Wife, Daughter any present"? That's the same as "Wife, Daughter all Not present".

Like this (omni y is a presence sensor):

Those two sensors are stand-ins for Wife and Daughter. This is the Condition for the Action to turn on the music.

Thank you! Will even work if I arrive at the same time as my wife (playlist will not start)

Just have to put a delay since my phones app updates faster than her phone.