Add A Shutoff Timer To Your Bathroom Fan

Adding this board (translated) to your bathroom fan will turn it into a smart device. It’s designed to automatically shut off the fan after it’s had some time to clear humidity from the room. It replaces the wall switch which normally controls these fans by converting the fan connection to always be connected to mains.  The board draws constant power to keep the ATtiny13 running via a half-wave rectification circuit. A single LED that rises from the center of the PCB lights up to signal that the fan is in operation, but it is also used as a light sensor, similar to the LED communications hack from a couple of days ago. When the lights go on in the bathroom the microcontroller will turn on the exhaust fan via a Triac. It will remain on until the light level in the bathroom drops.

There’s an interesting timing algorithm that delays the fan startup, and varies the amount of time it will stay on in the dark depending on how long the bathroom lights were on. This way, a longer shower (which will build up more humidity) will cause the fan to remain on for the base of five minutes, plus one minute longer for every two minutes the bathroom was in use. Pretty smart, and quite useful if your bathroom sees high traffic from several family members.

17 thoughts on “Add A Shutoff Timer To Your Bathroom Fan

  1. Pretty inter sting but a little overpowered for me I think. My extractor fan has an off the shelf (B&Q, not exactly speciality) timer.

    I wouldn’t have gone down the microcontroller route, but instead connect the fan to the mains the control board in parallel with the light, then just have a resistor and capacitor driving an SCR/triac or relay. The fan comes on when you switch the light on (capacitor charges/current glows to the triac) and switches off when the capacitor drains. SO your timing is set by the RC time constant. Simple and cheap. I know ATtiny13As are like £1.20, but I do love a simple analogue circuit!

  2. I wouldn’t use it, because I would really HATE to have something that automatically turns on the noisy bathroom fan every time i go in at two am to take a leak waking everyone up.

    I installed a $12 timer dial from home depot. Works great. Does anything from one minute to a full hour.

  3. Customise it. You don’t take a dump for less than 2 min and you don’t take a piss for more than 2 min right? So just add some dead time to this all starting.

    Love the power design. Running the microcontroller directly from mains through a bridge containing a zener. Neat. Dangerous too. Does this circuit have a specific name?

  4. Why bother with the “more minutes for a longer shower” feature? Why not just work out (A) the extraction rate of the fan (usually printed on it, but de-rate what it says to play safe) then work out (B) the volume of the bathroom. The maximum time you’d need is B/A.

  5. Mike, I’ve been thinking about building something like this myself for a while now. and I think the attiny route is perfect. Dunno why so many peeps have to leave neg replies – most of the fun is in building the thing (at least for me) who cares what makes it tick (I can cure my wife’s insomnia by explaining such things). Big advantage of microcontroller route is you can experiment with the software. The noisy fan at 2am problem is one I planned to overcome by using gradually falling and rising light levels to determine a rough period of night and then pwm the fan to run slower during the times ‘it’ thinks it needs to keep the noise down. Okay – I’m a geek – I need to get a life yada-yada but this is a useful as well as cool project. Well done mate.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.