AI and Sensor Driven System for Irrigation and Water Waste Minimization

DOI : 10.17577/IJERTV13IS040179

Download Full-Text PDF Cite this Publication

Text Only Version

AI and Sensor Driven System for Irrigation and Water Waste Minimization

Dr.S. Subasree Professor and Head, Department of CSE

Nehru Institute of Engineering and Technology Coimbatore, India

Dr.S. Sivakumar Assitant Professor (SG), Department of CSE

Nehru Institute of Engineering and Technology Coimbatore, India

Mr. Nandha Kumar Reddy Kaipa

Department of CSE Nehru Institute of Engineering

and Technology Coimbatore, India

Mr. Yaswanth Lekkala

Department of CSE Nehru Institute of Engineering

and Technology Coimbatore, India

Mr.Bhanu Teja L

Department of CSE Nehru Institute of Engineering

and Technology Coimbatore, India

Mr. Sarjin.S

Department of CSE Nehru Institute of Engineering

and Technology Coimbatore, India

Abstract With growing concerns about global water scarcity, agriculture faces a significant challenge in optimizing water usage. Traditional irrigation methods often lead to water waste due to imprecise scheduling and lack of real-time data on crop needs. This paper proposes an artificial intelligence (AI) and sensor-driven system for irrigation management, promoting water conservation and efficient irrigation practices. The system integrates real- time data from soil moisture sensors, temperature, and humidity sensors with a pre-trained machine learning model. By analyzing this data and considering crop selection, the model determines the optimal water delivery for different crops. The system utilizes Arduino, Node MCU (ESP8266) microcontrollers, the Blynk cloud platform, and an Internet of Things (IoT) application for data acquisition, processing, and user interaction. This approach offers real-time monitoring, automated irrigation control based on AI predictions, and user- friendly crop selection, fostering efficient water utilization and potentially increasing crop yields.

Keywords-Irrigation, Precision Agriculture, Artificial Intelligence, Machine Learning, Sensor Network, Internet of Things (IoT), Water Conservation


    Agriculture is a major consumer of freshwater resources, with traditional irrigation methods often leading to water wastage. Factors such as imprecise scheduling, evaporation, and runoff contribute to inefficient water utilization. Climate change further intensifies the need for sustainable water management practices in agricultural production. This paper presents

    an AI and sensor-driven system designed to optimize irrigation and minimize water waste.

    The proposed system leverages real-time data from a network of soil moisture sensors, a temperature and humidity sensor. This data is incorporated into a machine learning model trained on a comprehensive dataset containing crop water requirements, temperature, and humidity information. By analyzing real-time data and comparing it with the trained model, the system determines the optimal watering schedule for specific crops. This approach enables precise water delivery based on actual crop needs, minimizing water waste and promoting efficient irrigation practices.


    Several research efforts have explored the use of sensor networks and AI for precision agriculture applications, including irrigation management. Studies by [1] and [3] highlight the potential of IoT- based systems for collecting real-time data on soil moisture, temperature, and other environmental factors. These data can be used to automate irrigation scheduling and optimize water usage.

    Machine learning algorithms have also shown promise in irrigation control. Research by [2] demonstrates the effectiveness of using machine learning models trained on historical data to predict crop water requirements. This information can be used to adjust irrigation schedules dynamically, ensuring optimal water delivery.

    The proposed system builds upon these existing efforts by combining real-time sensor data, machine learning, and user-friendly interfaces to create a comprehensive irrigation optimization solution.


    The proposed system consists of the following hardware and software components:

    1. Hardware Components

      1. Water Tank

      2. Four Soil Moisture Sensors

      3. Temperature and Humidity Sensor

      4. Two Automatic Valves

      5. Water Pump Motor

      6. LCD Display Unit

      7. Arduino Uno or compatible microcontroller board

      8. NodeMCU (ESP8266) microcontroller

      9. Five Buttons for Crop Selection

    2. Software Components

      1. Dataset containing crop water requirements, temperature, and humidity data

      2. Machine learning model

      3. Blynk cloud platform

      4. IoT application for mobile phone or tablet

      1. Hardware Components

        1. Water Tank: Stores the water source for irrigation.

        2. Soil Moisture Sensors (4 units): Measure the volumetric water content in the soil. The average of readings from two sensors is used for each designated area.

          Fig:1. Soil moisture sensors

        3. Temperature and Humidity Sensor: Monitors ambient temperature and humidity levels.

          Fig: 2. DHT11 Sensor

        4. Automatic Valves (2 units): Control water flow to separate irrigation zones.

          Fig: 3. Solenoid valves

        5. Water Pump Motor: Delivers water from the tank to the irrigation system.

          Fig: 4. Water Motor

        6. LCD Display Unit: Provides real-time sensor data and a user interface for crop selection.

          Fig: 5. LCD display

        7. Arduino Uno: Microcontroller responsible for collecting sensor data and transmitting it to the Node MCU.

          Fig: 6. Arduino UNO

        8. Node MCU (ESP8266): Microcontroller with Wi-Fi connectivity, facilitating data transmission to the Blynk cloud platform.

          Fig: 7. Node MCU

        9. Five Buttons: Allow users to select the type of crop being grown in each irrigation zone.

        Fig: 8. Buttons

      2. Software Components

    1. Dataset: This dataset serves as the foundation for the machine learning model. It should include data points for various crop types, their water requirements at different growth stages, corresponding temperature ranges, and humidity levels.

      Fig: 9. Dataset

    2. Machine Learning Model: Trained on the dataset, the model learns the relationship between crop types, water requirements, temperature, and humidity. This model is then used to predict the optimal water needs for specific crops based on real-time sensor data.

    3. Blynk Cloud Platform: Provides a cloud- based interface for data storage, processing, and communication between the Node MCU and the mobile application. Blynk offers tools for creating user interfaces and functionalities for data visualization and control.

    4. IoT Application: A mobile application develped using the Blynk platform allows users to monitor the system's operation remotely. The application displays real-time sensor data (soil moisture, temperature, humidity), historical data trends, and potentially allows adjustments to pre-defined thresholds for soil moisture content.


    Fig: 10. Flow of data

    The system operates through the following steps:

    1. Data Acquisition

      1. The Arduino Uno continuously collects data from the soil moisture sensors (average of two sensors per zone), temperature and humidity sensor.

      2. This data is transmitted serially to the Node MCU microcontroller.

    2. Data Processing and Transmission

      1. The Node MCU receives the sensor data from the Arduino.

      2. The Node MCU connects to the Blynk cloud platform via Wi-Fi.

      3. The sensor data is sent to the Blynk cloud along with a crop selection signal based on the user's button press on the LCD display.

    3. Machine Learning Model and Irrigation Control

      1. The Blynk cloud platform stores the received data.

      2. The real-time sensor data and crop selection information are fed into the pre-trained machine learning model.

      3. The model analyzes the data and predicts the optimal water requirement for the selected crop based on its growth stage, considering the current temperature and humidity.

      4. Based on the model's prediction and a predefined threshold for soil moisture content, the Blynk cloud platform sends a control signal to the Node MCU.

    4. Irrigation Activation

      1. The Node MCU receives the control signal from the Blynk cloud.

      2. Based on the control signal and designated irrigation zone, the Node MCU activates the corresponding automatic valve.

      3. The water pump motor is turned on, delivering water to the designated irrigation zone.

    5. Monitoring and User Interface

      1. The Blynk cloud platform stores and displays real-time sensor data (soil moisture, temperature, humidity) on the user's mobile application or tablet.

      2. The mobile application allows users to monitor the system's operation, visualize

        historical data trends, and potentially adjust pre-defined thresholds for soil moisture content.

      3. The LCD display unit also shows real-time sensor data and provides a user interface for crop selection using the five buttons.


    The effectiveness of the system hinges on the accuracy of the machine learning model. Training the model involves:

      1. Data Collection: A comprehensive dataset is crucial. This dataset should encompass various crop types, their water requirements at different growth stages, corresponding temperature ranges, and humidity levels. Data can be sourced from agricultural databases, research papers, and field studies.

      2. Data Preprocessing: The collected data may require cleaning, normalization, and feature engineering to ensure compatibility with the chosen machine learning algorithm.

      3. Model Selection and Training:

        • Choosing Naïve Bayes algorithm, Naïve Bayes algorithm is a supervised learning algorithm, which is based on Bayes theorem and used for solving classification problems. It is mainly used in text classification that includes a high-dimensional training dataset. It is a probabilistic classifier, which means it predicts on the basis of the probability of an object.

        • Naïve: It is called Naïve because it assumes that the occurrence of a certain feature is independent of the occurrence of other features. Such as if the fruit is identified on the bases of color, shape, and taste, then red, spherical, and sweet fruit is recognized as an apple. Hence each feature individually contributes to identify that it is an apple without depending on each other.

        • Bayes: It is called Bayes because it depends on the principle of Bayes' Theorem.

        • Bayes' Theorem:

          Bayes' theorem is also known as Bayes'

          Rule or Bayes' law, which is used to determine

          the probability of a hypothesis with prior knowledge. It depends on the conditional probability.

          The formula for Bayes' theorem is given as:

          • P(A|B) is Posterior probability: Probability of hypothesis A on the observed event B.

          • P(B|A) is Likelihood probability: Probability of the evidence given that the probability of a hypothesis is true.

          • P(A) is Prior Probability: Probability of hypothesis before observing the evidence.

          • P(B) is Marginal Probability: Probability of Evidence.

            • The chosen algorithm is trained on the pre-processed dataset, enabling it to learn the relationships between crop types, water requirements, temperature and humidity.

      4. Model Evaluation: The trained model undergoes evaluation using a separate test dataset. This evaluation assesses the model's accuracy in predicting optimal water needs based on real- world data. Further refinement of the model may be necessary based on the evaluation results.

    Fig: 11. Sample Result

    Fig: 12. The final product


    The proposed AI and sensor-driven system offers several advantages:

    1. Precision Irrigation: By delivering water based on actual crop needs and real-time data, the system optimizes water usage and minimizes waste.

    2. Improved Crop Yields: Precise water management promotes optimal crop growth conditions, potentially leading to increased crop yields.

    3. Reduced Labor Costs: Automated irrigation control reduces the need for manual monitoring and adjustments, saving time and labour costs.

    4. Data-Driven Decision Making: The system provides valuable data on soil moisture, temperature, and humidity, enabling farmers to make informed decisions regarding irrigation practices and crop management.

    5. Scalability: The system can be scaled to accommodate larger fields by adding additional sensors, valves, and controllers.

    Potential applications of the system include:

    1. Commercial farms: Optimizing irrigation for various crops, including fruits, vegetables, and grains.

    2. Home gardens: Efficient water management for personal gardens and landscaping.

    3. Greenhouse applications: Precise control of irrigation for controlled environments.


    This paper presented an AI and sensor-driven system for irrigation optimization and water waste minimization. The system leverages real-time sensor data, machine learning, and user-friendly interfaces to deliver a comprehensive solution for sustainable water management in agriculture. By promoting precise water delivery based on specific crop needs, the system has the potential to improve water efficiency, enhance crop yields, and cntribute to a more sustainable agricultural future.


Further research and development efforts can enhance the system's capabilities:

  1. Integration with Advanced Sensors: Exploring the use of additional sensors like leaf wetness sensors or light intensity sensors can provide more comprehensive data for model training, potentially leading to even more precise irrigation control.

  2. Real-Time Weather Data Integration: Incorporating real-time weather data from weather stations or APIs can allow the model to adapt watering schedules based on upcoming weather events like rain or extreme heat.

  3. Cloud-Based Model Training and Updates: Utilizing cloud-based platforms for model training and updates can enable continuous improvement of the model's accuracy as more data is collected over time.

  4. Advanced Mobile Application Features: Developing features within the mobile application for data analysis, irrigation history visualization, and potential integration with farm management software can provide farmers with a comprehensive suite of tools for irrigation management.

By focusing on these areas of future work, the proposed AI and sensor-driven system can become an even more powerful tool for promoting sustainable water management practices and improving agricultural productivity.


  1. El Mehdi Raouhi, Mohamed Zouizza, Mohamed Lachgar, Younes Zouani, Hamid Hrimech, Ali Kartit, AIDSII: An AI-based digital system for intelligent irrigation, Software Impacts, Volume 17, 100574, ISSN 2665-9638, 2023.

  2. Y. Gao, "Design of Automatic Control System for Garden Irrigation Based on Artificial Intelligence Algorithms", pp. 435-440, doi: 10.1109/PEEEC60561.2023.00090, 2023

  3. B. Burkey, D. Pickerill, T. Adkins and M. Mittek, "Smart irrigation system", Computational Intelligence, vol. 38, no. 2, pp. 308-322, 2022.

  4. Shufian, M. R. Haider and M. Hasibuzzaman, "Results of a simulation to propose an automated irrigation & monitoring system in crop production using fast charging & solar charge controller", Journal of Cleaner Production, vol. 4, no. 1, pp. 165, 2021.

  5. Khriji, Sabrine & El Houssaini, Dhouha & Kammoun, Ines & Kanoun, Olfa. Precision Irrigation: An IoT-Enabled Wireless Sensor Network for Smart Irrigation Systems, 10.1007/978-3-030-49244-16, 2020.

  6. W. R. Mendes, F. M. U. Araujo, R. Dutta and D. M. Heeren, "Fuzzy control system for variable rate irrigation using remote sensing", Expert Systems with Applications, vol. 124, no. 7, pp. 13-24, 2019.

  7. Li Shuoming, Chen Lei and Chen Shihong, "An snn ontology based environment monitoring method for intelligent irrigation system", Journal of Shanghai Jiaotong University, vol. 23, no. 04, pp. 1-7, 2018.

  8. Daniel Rodríguez, J. Reca, Juan Martínez and M. Urrestarazu, "Automatic irrigation control system for soilless culture based on feedback from drainage hydrograph", Applied Engineering in Agriculture, vol. 33, no. 4, pp. 531-542, 2017.

  9. M. S. Mccready and M.D. Dukes, "Landscape irrigation scheduling efficiency and adequacy by various control technologies", Agricultural Water Management, vol. 98, no. 4, pp. 697-704, 2011.

  10. H. E. Nahry, R. R. Ali and A. A. E. Baroudy, "An approach for precision farming under pivot irrigation system using remote sensing and GIS techniques", Agricultural Water Management, vol. 98, no. 4, pp. 517-531, 2011.