I have done something similar with a Sonoff Dual in my toilet. The normal light switch is connected to the header near where the jack socket would be on a TH10. It switches the light on and off using outout 1. It's connected to openHAB. If light is only on for under 2 minutes the fan isn't operated. If over 2 minutes the fan comes on using output 2 and stays on for 1 minute after the light is turned off. You could replicate this in Rules. It won't dim of course but you may be able do that separately by feeding output 1 through a dimmer. In the UK we aren't allowed wall switches in bathrooms (must be a pull switch from the ceiling or a switch outside the bathroom).
I use a TH10 in the bathroom and control the fan using the humidity reading.
May or may not help you.
Regards
Phil K
--
You received this message because you are subscribed to the Google Groups "SonoffUsers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonoffusers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.