This circuit lets you control a pump, to keep the level of water in a cellar below a certain threshold, for example. Power is supplied to the pump by a battery that is recharged auto matically when the AC power line voltage is present.
12-volt Cellar Drain Pump Circuit Diagram:
lf the water level rises, the electrodes touch the liquid and a current begins to flow. The transistor then conducts and the pump runs. The pump stops when the water level has dropped sufficiently for the electrodes to no longer be in contact with it but not straight away, as the voltage on the transistor gate is maintained for a few seconds more by the 470 ytF capacitor. This makes it possible to ensure the electrodes are completely clear of the water.
The battery is constantly tested by the comparator circuit around the T1071 lC. lts output drives the gate of the triac in the transformer primary circuit via the optoisolator. The transformer secondary charges the battery via the rectifier, using as little power as possible, and in this way keeps the battery at 13.2 V.