So my 14 month old somehow managed to get the rail of her crib down (luckily she didn’t fall out). Now my wife is paranoid because our darling daughter has no fear and would swan dive from the top of her crib without hesitation. I placed a contact sensor on her crib and one on her door and fired up a rule that if both sensors are closed, and then the crib rails comes down (open) then the wife and I will get an alert. The problem is that the crib rail needs to be pulled up before it will go down. So the contact sensor opens for a split second, goes closed for a split second then goes open. So at the moment it sends me two notifications. (I’m thinking I can use a delay somewhere to get rid of the second notification).
Logic problem: I need to account for the crib rail starting in either position. (Up or down).
1st scenario is the crib rail is up.... go into room, close door behind you, pull the crib rail down to get the baby in, pull the rail back up, open the door, close the door behind.
2nd scenario is the same but without the need to put the rail down first.
Any ideas on the best way to set this up? Is the best way to create a rule that when both the crib and door are closed send the alert if the rail goes down. But only if the crib rail goes down after 2 min or something? Should I get a smart button and put it outside her room and use it to arm and disarm the rule?