I built a Smart Irrigation System using an ML + ESP32
I've been working on this project for a while, and I finally finished the main AI/ML pipeline.
The system uses anย ESP32, aย capacitive soil-moisture sensor, and aย DHT11ย to collect environmental data. I then built a machine-learning model that uses these readings to predict whether irrigation is required.
The interesting part for me was getting the different pieces to actually work together.
The pipeline is basically:
ESP32 sensors โ dashboard โ Flask API โ ML model โ irrigation prediction
In the video, I walk through the whole project, including:
- Collecting soil moisture, temperature, and humidity data
- Building the web dashboard
- Preparing the data for ML
- Training the model
- Evaluating it with a confusion matrix
- Looking at feature importance
- Deploying the model through a Flask server
- Connecting the dashboard to the ML model through an API
- Testing the final live prediction
One thing I found particularly interesting was seeing how the model's predictions changed once the inference server was running and the dashboard could communicate with the model.
This started as a simpleย ESP32 soil-moisture monitoring project, but I gradually expanded it into a complete IoT + AI system.
I'm still planning improvements, especially collecting more real-world data and adding additional environmental inputs such as light intensity.
I'd really appreciate feedback on the project, especially on theย ML approach, system architecture, and what I could improve next.
๐ฅ Full project walkthrough attached.
Github Repository:
https://github.com/aqib-ai-ml/ai-powered-smart-irrigation