

Open Proteus simulation tool, create a new file, then open the library and select the required components (Fig. Then build the entire project file to produce the hex file. Next, put a condition if reference voltage 2V is greater than or equal to the sensor signal. In the coding window, start code within the while loop to read the sensor output signal at AD0 pin of the microcontroller. Save the file three times with the same name but different extensions as indicated by the software. In ‘Program’ menu, select ‘Generate, Save and Exit’ option. Next, select ‘Enable Alphanumeric LCD Support’ option followed by Port C (PC0-RP6) with 16 characters. Then select ‘ADC Enabled’ option and set voltage reference as AREF pin with 1000kHz clock. Select the ATmega16 chip with 8MHz clock frequency, followed by output port as Port B0. In CodevisionAVR, open a new project and select ‘Target AVR Chip’ as ATmega. The coding and hex file were generated using the Evaluation version of CodeVisionAVR tool. The software was developed using four tools: CodeVisionAVR, Proteus, SinaProg and PCB Wizard. 3: Author’s prototype indicating the motor status in wet soil condition Software 2: Author’s prototype watering the plant in a flower pot Fig. 2 shows the author’s prototype with the moisture sensors embedded in the soil to be monitored. The motor pump status (‘on’ or ‘off’) and soil condition (‘dry’ or ‘wet’) are displayed on LCD1.įig.

When the soil is wet, i.e., soil voltage is less than the reference voltage, the logic-0 signal of the microcontroller turns the transistor, and hence the motor switches ‘off.’

The transistor conducts to energise relay RL1 (as its pole pin comes in contact with the N/O pin) and the motor turns on with power supply provided from the battery. If the soil is dry, i.e., the ground voltage is greater than the reference voltage, the microcontroller (ATmega16) gives a logic-1 output signal. DC motor pump M1 is connected between the normally-open (N/O) pin and pole of the relay. A BC548 transistor is used to drive relay RL1. The sensor circuit detects soil condition by measuring the soil voltage and comparing it with a reference voltage. 1: Circuit of automatic drip irrigation system It has three sections: sensor, microcontroller and water-pump motor circuits. Here we present an automatic drip irrigation system that senses the moisture level of the soil and automatically switches the pump on when the power is ‘on.’ Automatic drip irrigation system circuitĬircuit of the automatic drip irrigation system is shown in Fig. This can be achieved with the help of a single soil-moisture sensor and an AVR microcontroller.

Automation can help save water, electricity as well as human efforts. Conventional irrigation method wastes a lot of water, leading to a high cost of electricity to run the pump set for irrigation.
