Tank Motor Controller
The microcontroller(AT89C2051) used here is the brain of the circuit controlles all the desired function.It receives the signal of water sensing at pin no. 8(P3.4) from the IC 4049.Power supply is provided through a 12V/500mA transformer regulated for 5V by using IC7805.
Whenever the switch(SW) is pressed,buzzor produces sounds for 2 seconds & the relay energizes makes the whole circuit to a closed loop system until the water in the tank is not filled fully.During water filling LED blinks continuously.At last when water reaches to the top full level,the buzzor produces frequently generated sound about 20 times & motor goes switch-off.Vary the preset 470kΩ for better sensitivity of water.Two NPN transistors(BC548) are stand;one to drive the relay & another for buzzor.
The program is written as follows :
Project : Tank Motor Controller
Writer : Sameer Gupta
Date : June 2012
MCU : AT89C2051, XL : 12MHz */
sbit motor at P1.B7;
sbit buzzor at P1.B5;
sbit LED at P1.B3;
sbit signal at P3.B4;
unsigned short i;
delay_ms(3500); //3.5 Seconds signal receiving delay