Question regarding how to implement a bathroom automation

Hi All,

I have a question regarding an automation of which I haven’t been able to find something similar so I figured I’d start a new topic.

First off let me explain my setup:

  • hall way, with IKEA motion sensor
  • bathroom with ZBMINI-L2
  • bathroomdoor IKEA parasoll

I’ve been trying to create an automation that switches the zbmini on when someone is inside and off when leaving but I’m struggling with the conditions.

Enter: door open, turn light on:
if ZBMINI-L2 is off and door is open, switch ZBMINI-L2 on

Leave: if ZBMINI-L2 is on and the door is opened, switch ZBMINI-L2 off

These seem to contradict eachother because when I open the door when inside with the light on and close it, the light turns off, and then back on again.

Probably because the Enter automation kicks in.

Is there a way to do this without an additional motion sensor in the bathroom?

Edit: I’ve been looking at the Occupancy blueprint which looks very useful but it requires an additional motion sensor. If it turns out that’s the only way to do this correctly then that’s ok but I was hoping to solve this with just the sensors I have.

If they are both in the same automation then you might be able to have it in single mode and add a delay at the end of 10 seconds or so.
That should keep the other trigger from triggering.

Ok, so the opening as is and the closing:
if doorsensor open
and if ZBIMINI-L2 is on with duration 30 seconds?

I’ll try that. Thanks

Update: didn’t work. The light switches on again, I think because of the door open, light on automation. Is there way to make them operate in a sequence?

No…
Post the automation.

Search around the forums for “wasp in a box” or its other variants. I’m pretty sure you’ll be able to find ready made blueprints for such a scenario.