Bath fan quest: humidity + timer off unless double tap on

Not sure what topic to post this to, but here is my quest. I have a GE Enbrighten Toggle switch on a bath fan. That I want to use with a humidity sensor to turn it on and off. I also want to auto shut off after xx mins if the switch is used--Unless a double-tap up was used to turn it on.

I think I can use some community apps out there for the humidity-driven switch and also to auto shut off after nn minutes ... but any help on how to override a timer off with double tap up to turn on seems elusive? Will I need to build a custom timer-off rule to accomplish that and forgo a community app search for the timer-off? I am not that practiced at rules, but can sure try and give it a go with some pointers?

Does that all make sense?

Your double tap rule needs to have an added action of cancel rule timers which you choose the rule to be cancelled. Under that rule you have to set the cancelable to on

You can do this with conditional actions in Rule Machine. Tap and Double-tap are separate button presses. So you make the rule trigger the switch changed

The first conditional action cancels delayed actions, turns on the fan and exits the rule when the first button is pressed.

The second conditional action turns on the fan for 5 minutes ( or whatever delay you want) before turning it off.

Use double tap to enable a virtual switch, use the virtual switch to disable the app.

Grateful to all for the direction -- very helpful to get me started. Thank you!

Download the Hubitat app