Hi George,
That’s not easily possible, but please follow along:
When you run a flow with Check Status of all sensors there is no follow up on that action when no sensor is tripped, so basically it stops there.
When a sensor is tripped, the Sensor Active at Sensor check is activated and you can follow up on that by sending a message “the door/window … is open please close it”.
Now, it is possible to achieve what you want, but it gets a bit messy. You could set a variable when a sensor is tripped and keep checking for the variable to clear and then actually set the Surveillance Mode.
So, in the flow that has the card Check Status of all sensors set a variable to 0.
Now, in the flow that is triggered by Sensor Active at Sensor check do a +1 on the variable, to count all open sensors (or movement). Here’s the tricky part, you’ll have to have a flow on every sensor in your Surveillance Mode that triggers on closing the door/window or no motion detection and do a -1 on the before mentioned variable.
Somewhere that variable will become 0 again after all door/windows are closed and there’s no movement.
Next you need a flow that’s triggered on change of the variable and have a condition checking if for 0 (or < 0) and as the action set the Surveillance Mode.
Like I said, messy, but it can be done.