- When the switch is turned off, set Ignore Master Closet Sensor to True, delay as many seconds as specified in Seconds of Delay For Master Closet then set Ignore Master Closet Sensor to False
- Because I found the Rule Machine interface confusing to build this rule, I wanted to put a step by step on how to build this rule:
- Select Apps
- Select Rule Machine
- Select Create New Rule
- Name Rule
- Select Select Trigger Events
- Select Switch from the drop down
- Click the Switches Click to Set
- Select the correct switch
- Click the Update button or Switches Click to Set
- Click the Switch turns drop down
- Click off
- Click Done with this Trigger Event
- Click Done with Trigger Events
- Click Select Actions to Run
- Click Select Action Type to Add to get drop down
- Click Set Mode or Variables, Run Custom Action from the drop down
- Click Select Which Action to get drop down
- Click Set Variable from the drop down
- Click Click to set to get the Select Variable to Set drop down
- Click the global variable created earlier from the drop down. In my case that is Ignore Master Closet Sensor
- Click Click to set to get the options for the variable drop down
- Click True
- Click Done with this action
- Click Select Action Type to add to get drop down
- Click Delay or Repeat Actions, Wait from the drop down
- Click Select Which Action to get drop down
- Click Delay Actions from the drop down
- At this point if I wanted to come back and change the delay but modifying the rule directly you can, however, because I wanted it to be adjustable via the dashboard, I put the global variable (Seconds of Delay For Master Closet) into the Seconds field surrounded by % ie. %Seconds of Delay For Master Closet%
- Click Done with this action
- Click Select Action Type to add to get drop down
- Click Set Mode or Variables, Run Custom Action from the drop down
- Click Select Which Action to get drop down
- Click Set Variable from the drop down
- Click Click to set to get the Select Variable to Set drop down
- Click the global variable created earlier from the drop down. In my case that is Ignore Master Closet Sensor
- Click Click to set to get the options for the variable drop down
- Click False
- Click Done with this action
- Click Done with Actions
- Click Done
7. Test the automation
8. If the delay when the motion sensor will be ignored needs to be changed, then the variable's value either be changed inside Rule Machine or via the dashboard tile