The following schematic is a water level controller circuit diagram. It controls the water level inside a tank. This water level controller has two modes. The empty mode is when the controller will drain the tank if the water level reach the upper limit. Then the pump will be used to suck the water off the tank until the water level drop below the lower level. The other is the fill mode. The pump will fill the tank whenever the water level is drop below the lower limit. Until the water reach the upper limit, the pump will be activated. Following figure is the schematic :
This is a very simple design as only one IC package is used. This circuit uses NOR gates, one transistor is needed for the active component. The SW1 has default position in empty position. To make the water level controller works in fill mode, just switch it into the other position. Almost any type of water pump motors can use the relay. Take note that this circuit only works with water or liquid that is electrically conducive.