Soil Moisture Monitoring Using Field Programmable Gate Array

ABSTRACT


INTRODUCTION
Soil moisture is a key variable in controlling the exchange of water and heat energy between the land surface and the atmosphere through evaporation and plant transpiration. As a result, soil moisture plays an important role in the development of weather patterns and the production of precipitation. Therefore, used a particular Soil Sensor and integrated it with FPGA & Verilog code will help to control the benefit quantity of water for the soil.
The first integrated circuits that were developed in the early 1960s contained less than 100 transistors on a chip and are called small-scale integrated (SSI) circuits. The number of transistors continued to increase over the time, this trend has continued to the present day with 1,000,000 transistors on a chip by the late 1980s, 10,000,000 transistors on a chip by the mid-1990s, over 100,000,000 transistors by 2004, and up to1, 000,000,000 transistors on a chip today. This exponential growth in the amount of digital logic that can be packed into a single chip has produced serious problems for the digital designer. How can an engineer, or even a team of engineers, design a digital logic circuit that will end up containing millions of transistors? A completely different architecture was introduced in the mid-1980"s that uses RAM-based lookup tables instead of AND-OR gates to implement combinational logic. These devices are called field programmable gate arrays (FPGAs). The device consists of an array of configurable logic blocks (CLBs) surrounded by an array of I/O blocks.
The traditional way of designing digital circuits is to draw logic diagrams containing SSI gates and MSI logic functions. However, by the late 1980s and early 1990s such a process was becoming problematic. How can you draw schematic diagrams containing hundreds of thousands or millions of gates? As programmable logic devices replaced TTL chips in new designs a new approach to digital design became necessary. Computer-aided tools are essential to designing digital circuits today. What has become clear over the last decade is that today"s digital engineer designs digital systems by writing software! This is a major paradigm shift from the traditional method of designing digital systems. Many of the traditional design methods that were important when using TTL chips are less important when designing for programmable logic devices.
HDL is one of the two most common Hardware DescriptionLanguages (HDL) used by integrated circuit (IC) designers. The other one is VHDL. HDL"s allows the design to be simulated earlier in the design cycle in order to correct errors or experiment with different architectures. Designs described in HDL are technology-independent, easy to design and debug, and are usually more readable than schematics, particularly for large circuits. The basic model design scheme is presented as a flow chart in Figure 1  The DE0-Nano board introduces a compact-sized FPGA development platform suited for to a wide range of portable design projects, such as robots and mobile projects [1]. The DE0-Nano is ideal for use with embedded soft processors-it features a powerful Altera Cyclone IV FPGA (with 22,320 logic elements), 32 MB of SDRAM, 2 Kb EEPROM, and a 64 Mb serial configuration memory device. For connecting to realworld sensors the DE0-Nano includes a National Semiconductor 8-channel 12-bit A/D converter, and it also features an Analog Devices13-bit, 3-axis accelerometer device. The DE0-Nano board includes a built-in USB Blaster for FPGA programming, and the board can be powered either from this USB port or by an external power source. The board includes expansion headers that can be used to attach various Terasic daughter cards or other devices, such as motors and actuators. Inputs and outputs include 2 pushbuttons, 8 user LEDs and a set of 4 dip-switches.
A standalone device based on FPGA has been proposed that precisely detects the color of the soil to inspectthe macronutrients in the soil. The sensing unit consists of RBG LEDs along with a wide spectral image photodiodes to acquire high quality sensing results. The light reflected from the soil sample is collected by the photodetector diode. The FPGA module can be programmed to convert ADC data to corresponding HSI values [2]. Monitoring the moisture content, relative humidity and the temperature of crops and with a combination of microcontroller and FPGA based sensors have been proposed in [3]. Thus accurate and precise measurement sensors are required to measure transpiration. Moreover the power constraint present in WSN nodes has been addressed by using solar powered nodes [4]. Remote sensing and monitoring system with RFID sensor and readers show efficient performance along with energy harvesting capabilities at node level.A fusion of five primary sensors have been done to make a single sensor in order to monitor plant transmigration accurately. The proposed sensor measures air temperature, relative humidity, ambient light, leave temperature along with plant out relative permittivity [5-6]. The board comes with different types of interfaces and buses to be utilized according to application in hand. The PXI controller is a PC based controller that uses Windows as OS along with LabVIEW for controls. PC peripherals such as mouse, keyboard and monitor are interfaced via USB buses [7]. The board comes with different types of interfaces and buses to be utilized according to application in hand. The PXI controller is a PC based controller that uses Windows as OS along with LabVIEW for controls. PC peripherals such as mouse, keyboard and monitor are interfaced via USB buses [8][9]. Using smart set of multiple sensors to monitor the conditions of group of plants under controlled drought conditions. Similar type of plant were also treated in green house to draw a comparison between plant psychological behaviors. Finally Discrete wavelet transform as a digital filter was implemented on FPGA for noise cancellation and to detect drought conditions [10]. A distributed sensor networks for irrigation systems with multiple sensing nodes will allow producers to maximize the production while utilizing water resources efficient [11]. In addition to using distributed systems with multi-sensor sensing with a centralized system basedon FPGA for the agriculture industry has been proposed in [12].
Soil moisture is a key variable in controlling the exchange of water and heat energy between the land surface and the atmosphere through evaporation and plant transpiration. As a result, soil moisture plays an important role in the development of weather patterns and the production of precipitation. Therefore, used a particular Soil Sensor and integrated it with FPGA & Verilog code will help to control the best quantity of water for the soil. Thus in this work a real time FPGA based soil moisture monitoring system has been proposed. The project will utilize HDL language based on Altera board to implement the system. Different aspects of software and hardware implementation has been discussed in detail in this paper.

MATERIAL AND METHODS
The Soil Moisture Sensor module is used to measure the volumetric water content of soil. This sensor comes with 2 output pins which are digital or analog signal. User can choose whether to use the digital or analog output. It uses 2 probes to detect the moisture of the soil. When the surface of the probe plates touch the moisture soils, the current will be conducted between the 2 probes and LOW signal will be generated at its digital output. This sensor consists of a potentiometer knob that can be adjusted to change the sensitivity of the sensor. Figure 2 showes the Verilog HDL module for soil sensor system based FPGA block diagram. The design flow of the program in Verilog language has been presented by a flow chart presented in Figure 3.
The project block diagram shown in Figure 3 presents the flow in to several steps. The first stage is the multi-comparator board with soil moisture sensor that gathers the primary data upon with the Verilog module makes decision and at the third level the motor control system is used a response system. It is either turned on or off depending upon the decision taken by the central Verilog HDL module.

Hardware Implementation
The Soil Moisture Sensor module is used to measure the volumetric water content of soil. This sensor comes with 2 output pins which are digital or analog signal. User can choose whether to use the digital or analog output. It uses 2 probes to detect the moisture of the soil. When the surface of the probe plates touch the moisture soils, the current will be conducted between the 2 probes and LOW signal will be generated at its digital output. This sensor consists of a potentiometer knob that can be adjusted to change the sensitivity of the sensor. The soil moisture sensor used is presented in Figure 4.
The Single Channel Relay Module is a convenient board which can be used to control high voltage, high current load such as motor, solenoid valves, lamps and AC load. The used module has been shown in Figure 5. It is designed to interface with microcontroller such as Arduino, PIC and etc. The relays terminal (COM, NO and NC) is being brought out with screw terminal. It also comes with a LED to indicate the status of relay. It is designed to interface with microcontroller such as Arduino, PIC and etc. The relays terminal (COM, NO and NC) is being brought out with screw terminal. It also comes with a LED to indicate the status of relay. In this project AC Motor has been used to show the output from the DE0 Board based on the sensor values inputs.

SIMULATION AND IMPLEMENTATION
Following are the simulation parameters and the results for the proposed design scheme in the implementation.

Full Simulation I/O Results
The system implementation of the input and the output of the simulation model has been shown in Figure 6 and Figure 7. The flow chart for the logic diagram presented in Figure 6 shows the flow of the code for the gate level diagram. The diagram shows three different input levels for the gate array that are air, moisture and over moisture content. Upon these in put the decision is done for the electric motor to be switched on or not.

System Hardwave Implementation
The system proposed was implemented in real time on hardware for the soil monitoring system. The system was implemented using the DE0-Nano board. The implemented system was tested with test equipment and different types of conditions such as air, water, humidity. The sensor data was monitored and controlled using sensor node. The system used the sensed data to take actions such as turning the motor on irrigation or turning if off. Figure 8 shows the image with real time monitoring of the system. The complete setup presented in Figure 9 shows the experimentation setup where small samples of soil, muddy soil and air is show to be used for the experimention. The probe is dipped into the samples one by one and the sensor reads the moisture content reading. That reading is passed to the Altera FPGA board. The implemented algorithm then takes the desicison based on sensor moisture content reading whether or not to turn on the electric motor. While the most is powered by AC main with the relay module to control the high voltage load.

CONCLUSION
This project presents an implemention of an FPGA based implementation of a soil moisture sensing and monitoring system. The system utilites Verilog programming language for the implementation of an algorithm for the detection of moisture content in the soil and then taking appropriate actions to turn on the motor or not. The proposed system test different scenarios for the watering process such as the moisture water and air. The moisture sensor in placed in the soil, muddy water and the air one by one in order to give sensor conditions such as low moisture, over moisture and the dry conditions. Based on the data gathered by the sensor the FPGA board that is based on an Altera FPGA board it takes the decision on the bases on sensor reading. The algorithm for the proposed model is based in Verilog HDL language for better description of hardware system. The proposed system could provide efficient and automated watering and moisture control system to achieve efficient irrigation in agriculture industry.