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.