If you forget to switch off the light after leaving a seldom used room (such as the loft), there’s a strong likelihood that it could remain lit for months, running up an expensive power bill in the process. How can we prevent this waste? It’s not hard for electronics enthusiasts to design a little circuit to mitigate the effects of absentmindedness. The notion is simple; if the light is left on when the hatch or door is closed, a rhythmic sounder/buzzer signal produces an alarm that hopefully will not be masked by other noise.
The circuit is powered as long as the lamp bulb is switched on by light switch S1. If the reed switch S2 then signals that the hatch has been closed, the sounder operates. The red LED, mounted outside the loft next to the entry hatch, also indicates that the lamp up there needs to be switched off. The circuit does not use a transformer, meaning that the whole circuit is at mains potential. For this reason the components must be placed inside an insulated plastic case for protection, with no way that people can touch any part of the circuit (this includes the sounder).
The connecting wires to the LED and the reed switch contact must be fully protected to the same touch-proof degree too. For the sounder you can use any type that operates on direct current in the region between 1 V and 3 V. In this circuit the operating voltage is limited by the LED connected in parallel to the buzzer. Using a red LED will provide around 1.7 V to the sounder. The current requirement of this kind of miniature sounder is about 5 mA.
circuit from http://www.extremecircuits.net/2010/05/put-that-light-out.html