Vous êtes sur la page 1sur 33

ABSTRACT

The project we have undertaken is Automatic Plant Irrigation System. This project is taken up as India is an agriculture oriented country and the rate at which water resources are depleting is a dangerous threat hence there is a need of smart and efficient way of irrigation. In this project we have implemented sensors which detect the humidity in the soil (agricultural field) and supply water to the field which has water requirement. The project is 8051 microcontroller based design which controls the water supply and the field to be irrigated. There are sensors present in each field which are not activated till water is present on the field. Once the field gets dry sensors sense the requirement of water in the field and send a signal to the microcontroller. Microcontroller then supply water to that particular field which has water requirement till the sensors is deactivated again. In case, when there are more than one signal for water requirement then the microcontroller will prioritize the first received signal and irrigate the fields accordingly.

1. INTRODUCTION
In the fast paced world human beings require everything to be automated. Our life style demands everything to be remote controlled. Apart from few things man has made his life automated. And why not ? In the world of advance electronics, life of human beings should be simpler hence to make life more simpler and convenient, we have made AUTOMATIC PLANT IRRIGATION SYSTEM. A model of controlling irrigation facilities to help millions of people. This model uses sensor technology with microcontroller to make a smart switching device. The model shows the basic switching mechanism of Water motor/pump using sensors from any part of field by sensing the moisture present in the soil. Our basic model can be extended to any level of switching & controlling by using DTMF .

2.BLOCK DIAGRAM

PROBES TO SOIL LCD SCREEN MICRO CONTROLLER AT89S52

SENSOR CIRCUIT

MOTOR DRIVER CIRCUIT

DC MOT0R

POWER SUPPLY

3.CIRCUIT DIAGRAM

4.WORKING
Initially 12v voltage is given to motor driver circuit to drive the motor and to the microcontroller. The condition of soil in the field is sensed and compare with the reference voltage(5v) this is done by the timer 555 IC in sensor circuit. When the soil condition is dry i.e,lower than reference voltage in the field, the high signal(logic 1) appears on the output PORT 3 of the sensor. The output pin of the sensor is connected to the PORT 39 of microcontroller. The output of microcontroller PORT 21 is given as input to the motor driver circuit(L293D) at PORT 2 and makes motor to switch ON and supply water to field. Now when the soil becomes wet i.e, higher than reference voltage, the sensor sends low signal (logic 0) to microcontroller. When microcontroller receives this signal , it switch OFF the motor which is connected at PORT 3 of the motor driver circuit. The microcontroller output pins(PORT 1 to P0RT 8. 10,11,16) are connected to LCD screen which is used to display the condition of soil and motor. In this manner, whenever the field is in dry condition the motor is switch ON and supplies water to the field. This complete the design of Automatic Plant Irrigation System using Microcontroller.

5. COMPONENTS LIST
Microcontroller Transformer Comparator Voltage Regulator Crystal oscillator Diode LED Resistor : 470 ohm (for LED) , 8.2 K (for power on Reset Ckt. ), 10 K (for sensors) , potentiometer(100K) Capacitor LCD DC Motor AC Adapter : 1000 uf(for Power supply),10 uf(reset) 33p F( for crystal oscillator) : 16 x 2 : AT89S52 : Step down transformer (220/12) : IC 555 : IC 7805 : 11.0592 M Hz : IN 4007

6.COMPONENT DESCRIPTION
I). 8051 CONTROLLER The Intel 8051 is an 8-bit microcontroller which means that most available operations are limited to 8 bits. There are 3 basic "sizes" of the 8051: Short, Standard, and Extended. The Short and Standard chips are often available in DIP (dual in-line package) form, but the Extended 8051 models often have a different form factor, and are not "drop-in compatible". All these things are called 8051 because they can all be programmed using 8051 assembly language, and they all share certain features (although the different models all have their own special features). Some of the features that have made the 8051 popular are: 4 KB on chip program memory. 128 bytes on chip data memory(RAM). 4 reg banks. 128 user defined software flags. 8-bit data bus 16-bit address bus 32 general purpose registers each of 8 bits 16 bit timers (usually 2, but may have more, or less). 3 internal and 2 external interrupts. Bit as well as byte addressable RAM area of 16 bytes. Four 8-bit ports, (short models have two 8-bit ports). 16-bit program counter and data pointer. 1 Microsecond instruction cycle with 12 MHz Crystal.

8051 models may also have a number of special, model-specific features, such as UARTs, ADC, OpAmps, etc... PIN CONFIGURATION PIN 9: PIN 9 is the reset pin which is used reset the microcontrollers internal registers and ports upon starting up. (Pin should be held high for 2 machine cycles.) PINS 18 & 19: The 8051 has a built-in oscillator amplifier hence we need to only connect a crystal at these pins to provide clock pulses to the circuit. PIN 40 and 20: Pins 40 and 20 are VCC and ground respectively. The 8051 chip needs +5V 500mA to function properly, although there are lower powered versions like the Atmel 2051 which is a scaled down version of the 8051 which runs on +3V. PINS 29, 30 & 31: As described in the features of the 8051, this chip contains a built-in flash memory. In order to program this we need to supply a voltage of +12V at pin 31. If external memory is connected then PIN 31, also called EA/VPP, should be connected to ground to indicate the presence of external memory. PIN 30 is called ALE (address latch enable), which is used when multiple memory chips are connected to the controller and only one of them needs to be selected.We will deal with this in depth in the later chapters. PIN 29 is called PSEN. This is "program store enable". In order to use the external memory it is required to provide the low voltage (0) on both PSEN and EA pins. There are 4 8-bit ports: P0, P1, P2 and P3. PORT P1 (Pins 1 to 8): The port P1 is a general purpose input/output port which can be used for a variety of interfacing tasks. The other ports P0, P2 and P3 have dual roles or additional functions associated with them based upon the context of their usage. PORT P3 (Pins 10 to 17): PORT P3 acts as a normal IO port, but Port P3 has additional functions such as, serial transmit and receive pins, 2 external interrupt pins, 2 external counter inputs, read and write pins for memory access. PORT P2 (pins 21 to 28): PORT P2 can also be used as a general purpose 8 bit port when no external memory is present, but if external memory access is required then PORT P2 will act as an address bus in conjunction with PORT P0 to access external memory. PORT P2 acts as A8-A15, as can be seen from fig 1.1 PORT P0 (pins 32 to 39) PORT P0 can be used as a general purpose 8 bit port when no external memory is present, but if external memory access is required then PORT P0 acts

as a multiplexed address and data bus that can be used to access external memory in conjunction with PORT P2. P0 acts as AD0-AD7,

PIN DIAGRAM II) .TRANSFORMER

IMAGE OF TRANSFORMER 9

Usually, DC voltages are required to operate various electronic equipment and these voltages are 5V, 9V or 12V. But these voltages cannot be obtained directly. Thus the a.c input available at the mains supply i.e., 230V is to be brought down to the required voltage level. This is done by a transformer. Thus, a step down transformer is employed to decrease the voltage to a required level. Basic principles: The transformer is based on two principles: first, that an electric current can produce a magnetic field (electromagnetism), and, second that a changing magnetic field within a coil of wire induces a voltage across the ends of the coil (electromagnetic induction). Changing the current in the primary coil changes the magnetic flux that is developed. The changing magnetic flux induces a voltage in the secondary coil.

III) IC 555 TIMER The 555 timer IC is an integrated circuit (chip) used in a variety of timer, pulse generation, and oscillator applications. The 555 can be used to provide time delays, as an oscillator, and as a flip-flop element. Derivatives provide up to four timing circuits in one package.

10

IMAGE OF IC 555

IC 555 PIN DIAGRAM PIN 5 is also called control voltage pin! By applying a voltage to the CONTROL VOLTAGE input, pin 5, you can alter the timing characteristics of the device. In most applications, the CONTROL VOLTAGE input is not used. It is usual to connect a 10 nF capacitor between pin 5 and 0 V to prevent interference. The CONTROL VOLTAGE input can be used to build an astable with a frequency modulated output.

Pin Name 1 2 GND TRIG Ground, low level (0 V)

Purpose

OUT rises, and interval starts, when this input falls below 1/3 VCC.

11

OUT

This output is driven to approximately 1.7V below +VCC or GND. A timing interval may be reset by driving this input to GND, but the timing

RESET does not begin again until RESET rises above approximately 0.7 volts. Overrides TRIG which overrides THR.

5 6

CTRL "Control" access to the internal voltage divider (by default, 2/3 VCC). THR The interval ends when the voltage at THR is greater than at CTRL. Open collector output; may discharge a capacitor between intervals. In phase with output. Positive supply voltage is usually between 3 and 15 V.

DIS

VCC

Modes

The 555 has three operating modes:

Monostable mode: in this mode, the 555 functions as a "one-shot" pulse generator. Applications include timers, missing pulse detection, bouncefree switches, touch switches, frequency divider, capacitance measurement, pulsewidth modulation (PWM) and so on. Astable: free running mode: the 555 can operate as an oscillator. Uses include LED and lamp flashers, pulse generation, logic clocks, tone generation, security alarms, pulse position modulation and so on. The 555 can be used as a simple ADC, converting an analog value to a pulse length. E.g. selecting a thermistor as timing resistor allows the use of the 555 in a temperature sensor: the period of the output pulse is determined by the temperature. The use of a

12

microprocessor based circuit can then convert the pulse period to temperature, linearize it and even provide calibration means.

Bistable mode or Schmitt trigger: the 555 can operate as a flip-flop, if the DIS pin is not connected and no capacitor is used. Uses include bounce-free latched switches.

IV). VOLTAGE REGULATOR IC 7805 This is most common voltage regulator that is still used in embedded designs. LM7805 voltage regulator is a linear regulator made by several manufacturers like Fairchild, or ST Microelectronics. They can come in several types of packages. For output current up to 1A there may be two types of packages: TO-220 (vertical) and DPAK (horizontal).

With proper heat sink these LM78xx types can handle even more than 1A current. They also have Thermal overload protection, Short circuit protection. If your design wanna exceed 0.1A current you may chose regulator LM78L05 with smaller packages and lower maximum current up to 0.1A. They come in three main types of packages SO-8, SOT-89 and TO-92

13

V). CRYSTAL OSCILLATOR

IMAGE OF CRYSTAL OSCILLATOR

SYMBOL

A crystal oscillator is an electronic oscillator circuit that uses the mechanical resonance of a vibrating crystal of piezoelectric material to create an electrical signal with a very precise frequency. This frequency is commonly used to keep track of time (as in quartz wristwatches), to provide a stable clock signal for digital integrated circuits, and to stabilize frequencies for radio transmitters and receivers. The most common type of piezoelectric resonator used is the quartz crystal, so oscillator circuits designed around them became known as "crystal oscillators." Quartz crystals are manufactured for frequencies from a few tens of kilohertz to tens of megahertz. More than two billion (2109) crystals are manufactured annually. Most are used for consumer devices such as wristwatches, clocks, radios, computers, and cellphones. Quartz crystals are also found inside test and measurement equipment, such as counters, signal generators, and oscilloscopes.

14

VI).DIODE

IMAGE OF DIODE SYMBOL The 1N4007 series (or 1N4000 series) is a family of popular 1.0 amp general purpose silicon rectifier diodes commonly used in AC adapters for common household appliances. Blocking voltage varies from 50 to 1000 volts. This diode is made in an axiallead DO-41 plastic package. The 1N5400 series is a similarly popular series for higher current applications, up to 3 A. These diodes come in the larger DO-201 axial package. These are fairly low-speed rectifier diodes, being inefficient for square waves of more than 15 kHz. The series was second sourced by many manufacturers. The 1N4000 series were in the Motorola Silicon Rectifier Handbook in 1966, as replacements for 1N2609 through 1N2617. The 1N5400 series were announced in Electrical Design News in 1968, along with the now lesser known 1.5-ampere 1N5391 series. These devices are widely used and recommended. The table below shows the maximum repetitive reverse blocking voltages of each of the members of the 1N4000 and 1N5400 series

15

VII). LED A light-emitting diode (LED) is a semiconductor light source.[4] LEDs are used as indicator lamps in many devices and are increasingly used for other lighting. Appearing as practical electronic components in 1962,[5] early LEDs emitted lowintensity red light, but modern versions are available across the visible, ultraviolet, and infrared wavelengths, with very high brightness.

LED

Symbol of LED

When a light-emitting diode is forward-biased (switched on), electrons are able to recombine with electron holes within the device, releasing energy in the form of photons. This effect is called electroluminescence and the color of the light (corresponding to the energy of the photon) is determined by the energy gap of the semiconductor. An LED is often small in area (less than 1 mm2), and integrated optical components may be used to shape its radiation pattern.[6] LEDs present many advantages over incandescent light sources including lower energy consumption, longer lifetime, improved physical robustness, smaller size, and faster switching. LEDs powerful enough for room lighting are relatively expensive and require more precise current and heat management than compact fluorescent lamp sources of comparable output. Light-emitting diodes are used in applications as diverse as aviation lighting, automotive lighting, advertising, general lighting, and traffic signals. LEDs have allowed new text, video displays, and sensors to be developed, while their high switching rates are also useful in advanced communications technology. Infrared LEDs are also used in the

16

remote control units of many commercial products including televisions, DVD players, and other domestic appliances. The LED consists of a chip of semiconducting material doped with impurities to create a p-n junction. As in other diodes, current flows easily from the p-side, or anode, to the n-side, or cathode, but not in the reverse direction. Charge-carriers electrons and holes flow into the junction from electrodes with different voltages. When an electron meets a hole, it falls into a lower energy level, and releases energy in the form of a photon. The wavelength of the light emitted, and thus its color depends on the band gap energy of the materials forming the p-n junction. In silicon or germanium diodes, the electrons and holes recombine by a nonradiative transition, which produces no optical emission, because these are indirect band gap materials. The materials used for the LED have a direct band gap with energies corresponding to near-infrared, visible, or near-ultraviolet light.

VIII). RESISTOR A resistor is an electrical component that limits or regulates the flow of electrical current in an electronic circuit. Resistors can also be used to provide a specific voltage for an active device such as a transistor. All other factors being equal, in a directcurrent (DC) circuit, the current through a resistor is inversely proportional to its resistance, and directly proportional to the voltage across it. This is the well-known Ohm's Law. In alternating-current (AC) circuits, this rule also applies as long as the resistor does not contain inductance or capacitance.

IMAGE OF RESISTOR

SYMBOL

17

Resistors can be fabricated in a variety of ways. The most common type inelectronic devices and systems is the carbon-composition resistor. Finegr anulated carbon (graphite) is mixed with clay and hardened. The resistance depends on the proportion of carbon to clay; the higher this ratio, the lower the resistance. Another type of resistor is made from winding Nichrome or similar wire onan insulating form. This component, called a wire wound resistor, is able to handle higher currents than a carbon-composition resistor of the same physical size. However, because the wire is wound into a coil, the component acts as an inductors as well as exhibiting resistance. This does not affect performance in DC circuits, but can have an adverse effect in AC circuits because inductance renders the device sensitive to changes in output. IX). CAPACITOR

IMAGE OF ELECTROLYTIC CAPACITOR

IMAGE OF CERAMIC CAPACITOR

A capacitor is a tool consisting of two conductive plates, each of which hosts an opposite charge. These plates are separated by a dielectric or other form of insulator, which helps them maintain an electric charge. There are several types of insulators used in capacitors. Examples include ceramic, polyester, tantalum air, and polystyrene. Other common capacitor insulators include air, paper, and plastic. Each effectively prevents the plates from touching each other. A capacitor is often used to store analogue signals and digital data. Another type of capacitor is used in the telecommunications equipment industry. This type of capacitor is

18

able to adjust the frequency and tuning of telecommunications equipment and is often referred to a variable capacitor. A capacitor is also ideal for storing an electron. A capacitor cannot, however, make electrons. A capacitor measures in voltage, which differs on each of the two interior plates. Both plates of the capacitor are charged, but the current flows in opposite directions. A capacitor contains 1.5 volts which is the same voltage found in a common AA battery. As voltage is used in a capacitor, one of the two plates becomes filled with a steady flow of current. At the same time, the current flows away from the other plate. To understand the flow of voltage in a capacitor, it is helpful to look at naturally occurring examples. Lightning, for example, is similar to a capacitor. The cloud represents one of the plates and the ground represents the other. The lightning is the charging factor moving between the ground and the cloud. X). LCD

Liquid Crystal Display

19

Liquid crystal displays (LCD) are widely used in recent years as compares to LEDs. This is due to the declining prices of LCD, the ability to display numbers, characters and graphics, incorporation of a refreshing controller into the LCD, their by relieving the CPU of the task of refreshing the LCD and also the ease of programming for characters and graphics. HD 44780 based LCDs are most commonly used. Pin Symbol I/O Description 1 VSS - Ground 2 VCC - +5V power supply 3 VEE - Power supply to control contrast 4 RS I RS=0 to select command register, RS=1 to select data register. 5 R/W I R/W=0 for write, R/W=1 for read 6 E I/O Enable 7 PB0 I/O The 8 bit data bus 8 PB1 I/O The 8 bit data bus 9 DB2 I/O The 8 bit data bus 10 DB3 I/O The 8 bit data bus 11 DB4 I/O The 8 bit data bus 12 DB5 I/O The 8 bit data bus 13 DB6 I/O The 8 bit data bus 14 DB7 I/O The 8 bit data bus XI). DC MOTOR

20

IMAGE OF DC MOTOR An electric motor is a machine which converts electrical energy into mechanical energy. DC motors are configured in many types and sizes, including brush less,servo, and gear motor types. A motor consists of a rotor and a permanent magnetic field stator. The magnetic field is maintained using either permanent magnets or electromagnetic windings. DC motors are most commonly used in variable speed and torque. The physical principle behind production of mechanical force by the interactions of an electric current and a magnetic field, Faraday's law of induction, was discovered by Michael Faraday in 1831. Electric motors of increasing efficiency were constructed from 1821 through the end of the 19th century, but commercial exploitation of electric motors on a large scale required efficient electrical generators and electrical distribution networks. The first commercially successful motors were made around 1873 by Znobe Gramme. Some devices convert electricity into motion but do not generate usable mechanical power as a primary objective, and so are not generally referred to as electric motors. For example, magnetic solenoids and loudspeakers are usually described as actuators and transducers respectively, instead of motors. Some electric motors are used to produce torque or force XII).AC ADAPTER

21

The AC adapter, AC/DC adapter or AC/DC converter[1] is a type of external power supply, often enclosed in a case similar to an AC plug. Other names include plug pack, plug-in adapter, adapter block, domestic mains adapter, line power adapter, or power adapter. AC adapters are used with electrical devices that require power but do not contain internal components to derive the required voltage and power from mains power. The internal circuitry of an external power supply is very similar to the design that would be used for a built-in or internal supply.

External power supplies are used both with equipment with no other source of power and with battery-powered equipment, where the supply, when plugged in, can sometimes charge the battery in addition to powering the equipment. Use of an external power supply allows portability of battery-powered equipment without the added bulk of internal power components and makes it unnecessary to produce equipment for use only with a specified power source.

22

7.PROGRAM
;soil moisure based water irrigation control system $mod51 org 0000H MOV A,#0FFH MOV P0,A MOV A,#00H MOV P1,A MOV P3,A MOV P2,A setb p2.0 l1: MOV A,P0 JB P0.0,ch1

23

l2:

JNB P0.0,ch2 SJMP l1

ch1: setb p2.0 acall sms1 sjmp l2 ch2: clr p2.0 acall sms2 sjmp l1 sms1: MOV A,#38H ACALL COMNWRT ACALL DELAY MOV A,#0EH ACALL COMNWRT ACALL DELAY MOV A,#01H ACALL COMNWRT ACALL DELAY MOV A,#80H ACALL COMNWRT ACALL DELAY

24

MOV A,#'S' ACALL DATAWRT ACALL DELAY MOV A,#'O' ACALL DATAWRT ACALL DELAY MOV A,#'I' ACALL DATAWRT ACALL DELAY MOV A,#'L' ACALL DATAWRT ACALL DELAY MOV A,#':' ACALL DATAWRT ACALL DELAY MOV A,#'D' ACALL DATAWRT ACALL DELAY MOV A,#'R' ACALL DATAWRT ACALL DELAY MOV A,#'Y' ACALL DATAWRT ACALL DELAY

25

MOV A,#' ' ACALL DATAWRT ACALL DELAY MOV A,#'P' ACALL DATAWRT ACALL DELAY MOV A,#'U' ACALL DATAWRT ACALL DELAY MOV A,#'M' ACALL DATAWRT ACALL DELAY MOV A,#'P' ACALL DATAWRT ACALL DELAY MOV A,#':' ACALL DATAWRT ACALL DELAY MOV A,#'O' ACALL DATAWRT ACALL DELAY MOV A,#'N' ACALL DATAWRT

26

ACALL DELAY ret sms2: MOV A,#38H ACALL COMNWRT ACALL DELAY MOV A,#0EH ACALL COMNWRT ACALL DELAY MOV A,#01H ACALL COMNWRT ACALL DELAY MOV A,#80H ACALL COMNWRT ACALL DELAY MOV A,#'S' ACALL DATAWRT ACALL DELAY MOV A,#'O' ACALL DATAWRT ACALL DELAY MOV A,#'I' ACALL DATAWRT

27

ACALL DELAY MOV A,#'L' ACALL DATAWRT ACALL DELAY MOV A,#':' ACALL DATAWRT ACALL DELAY MOV A,#'W' ACALL DATAWRT ACALL DELAY MOV A,#'E' ACALL DATAWRT ACALL DELAY MOV A,#'T' ACALL DATAWRT ACALL DELAY MOV A,#' ' ACALL DATAWRT ACALL DELAY MOV A,#'P' ACALL DATAWRT ACALL DELAY MOV A,#'U'

28

ACALL DATAWRT ACALL DELAY MOV A,#'M' ACALL DATAWRT ACALL DELAY MOV A,#'P' ACALL DATAWRT ACALL DELAY MOV A,#':' ACALL DATAWRT ACALL DELAY MOV A,#'O' ACALL DATAWRT ACALL DELAY MOV A,#'F' ACALL DATAWRT ACALL DELAY ret COMNWRT: MOV P1,A CLR P3.1 SETB P3.0 CLR P3.0 RET

29

DATAWRT: MOV P1,A SETB P3.1 SETB P3.0 CLR P3.0 RET DELAY: MOV R3,#50 HERE2: MOV R4,#255 HERE: DJNZ R4,HERE DJNZ R3,HERE2 RET end

8. APPLICATION
Irrigation In Fields. Irrigation In Gardens, Parks. Very Efficient For Paddy, Rice Fields.
Picsiculture.

30

9.MERITS & DEMERITS


MERITS:
Highly sensitive, Low cost and reliable circuit. Works according to the soil condition. Complete elimination of manpower.

Can handle heavy loads up to 7A


System can be switched into manual mode whenever required.

DEMERITS: This is applicable for only large farms. Require frequent maintenance for effective operation. Have limited life after installation due to the detoriation of the plastic component in a hot, arid climate when exposed to ultraviolet light.

31

10.FUTURE EXTENSION
The working of project is basically dependent on the output of the humidity sensors. Whenever there is need of excess water in the desired field(RICE crops) then it will not be possible by using sensor technology. For this we will have to adopt the DTMF technology. By using this we will be able to irrigate the desired field & in desired amount.

32

11.REFERENCES
Muhammad Ali Mazidi , The 8051 Microcontroller & Embedded Systems Ramesh S.Gaonkar, Micro processor Architecture, Programming & Applications D.V.Prasad, Electronic Components

33

Vous aimerez peut-être aussi