Monitor the pH levels of a hydroponic plant’s water supply with Arduino and tinyML
September 2nd, 2021—
Many plants are notorious for how picky they are about their environmental conditions. Having the wrong temperature, humidity, soil type, and even elevation can produce devastating effects. But none are perhaps as important and overlooked as water/soil pH, which is a measure of how acidic and/or alkaline the growing medium is. In hydroponics, maintaining optimal growing conditions is how high yields can be ensured without becoming too wasteful. Janet N on Hackster had the idea of harnessing the powers of embedded machine learning to let her know when the water had become unacceptable for her plants.
The device uses an Arduino Nano 33 BLE Sense to continuously monitor the pH of the hydroponics water supply with a simple probe. This data was initially loaded into Edge Impulse’s Studio where it was split into features and then sent to both a Keras classification model and an anomaly detection model for training. After she was satisfied with the performance of both, they were deployed back onto the Arduino.
As the system checks the pH of the water, it aggregates the data and places it into a buffer for classification. If the value is higher than 7, the soil is too basic, and a yellow LED is turned on. If the soil is too acidic (below 4), a red LED is activated. And finally, a green LED lights up when the optimal pH of around 5 has been reached.
You can read more about the process of creating this project here on Hackster.io.