Here it is shown how the automatic water overflow controller works with simulation in Proteus. This is continuation of the tutorial how to make Water Tank Overflow Detector using Soil Moisture Sensor. In that previous introductory tutorial it is described in details how the water level controller works. Here we explain with simulation in proteus electronics design software how this work.
The following is the circuit diagram of the water overflow controller build with YL-69 soil moisture sensor and Arduino.
In the above circuit drawing, the DC water pump motor is controlled using Arduino depending upon the state of the push button and the soil moisture sensor. First, the pump motor is turned on by pressing on the push button which is connected to pin 2 of Arduino. This turns on the water pump which pumps water from the lower tank to the upper tank. The water pump motor is turned on and off using the MOSFET N7000 transistor. The moisture sensor is fitted at the top of the upper water tank. When the upper tank gets filled and water level reaches the top, the sensor detects the water and outputs LOW signal at its digital output pin DO. This YL-69 DO sensor pin is connected to the digital pin 9 of the Arduino. Arduino constantly monitors this pin and when it detects that the signal is low it turns off the water pump and the water flow from lower tank to upper tank stops. In this way, the water overflow in a tank can be detected using the soil sensor and water pump motor automatically stopped.
See the following simulation video of water overflow controller in Proteus.
Here we have used simple MOSFET N7000 transistor as a switch which can be controlled by microcontroller or microcontroller board like Arduino. Here we have used protection diode. We can also use motor driver IC like L298N or L293D. See for example the tutorial Arduino L298N DC Motor Speed control with PWM and DC motor control using L293D Motor Shield and Arduino. Such motor driver IC can handle more current and have protection diode build into them.
In the next tutorial we show how the actual water overflow controller works.