It all started when I first had to leave my apartment for two weeks and leave my plants while they were in the root developing phase, that's when I had to figure out a solution to fight both water deficiency and darkness. And with that in mind, "Watero" was born!
"Watero" is a smart irrigation system combined with UV growth led mounted in an incubator that presents the perfect solution to maintain plants' health and helps them grow in the best way possible.
How it Works:for this project, we chose to build a modular system where an esp32 lolin will be a node that collects data from sensors from Seeed Studio, and a Wio terminal will be our HMI (Human Machine Interface).
Both the HMI and the node will communicate via adafruit io using MQTT protocol, though for extra availability the Esp32 node will be connected to Arduino Cloud since it provides easy-to-make dashboards and a wide range of libraries and provides a mobile application for easy access to our setup, Also the Wio terminal will be connected to a LoraWAN network via the LoraWAN module provided from Seeed Studio.
Hardware Setup:Step1: Install water dripping set + water pumps:
- For this step you are free to choose the setup that you like most, in our case the water pipes and dripping set will be installed in an incubator since we want to protect the plants from cold and wind as shown in the picture :
- The water pumps are submerged in a big tunk of water connected to the water pipes setup.
Step2: Installing UV growth LEDs:
- As shown in the picture below, we have chosen these LED strips for the growth lights imitation as it gets darker during winter and plants need more lighting:
Step3: esp32 setup:
- connect all the Grove SHT4x/SHT31 to the Esp32 using the I2C interface :
- connect the Grove soil moist sensor to an analog Pin of the Esp32.
- to be able to control the pumps and UV light strip, we've decided to use relays as a medium of control to switch between ON and OFF states. The esp32 is then connected to "Arduino cloud" which offers a control interface we'll go through it in the next steps.
Step1: connecting ESP32 to Arduino cloud:
- go to https://cloud.arduino.cc/ and make a free account
- follow this documentation to perform the next steps: https://docs.arduino.cc/arduino-cloud/getting-started/iot-cloud-getting-started
- connect your device to your account
- create your sketch
- and finally, you can create a simple dashboard like this one :
Also, you can download an app "IoT Remote"on your phone to control the pump(s) and the UV light, you just need to log in using the same credentials :
Step 2: Preparing the Wio terminal :
- create a simple visual dashboard for the HMI where we will show temperature, humidity, and moisture readings, also we will display the status of the relays that we will receive through the Adafruit io platform:
//the dashboard part // should be inside the loop func
tft.setTextColor(TFT_BLACK, TFT_WHITE);
tft.setFreeFont(&FreeSansBoldOblique12pt7b);
//select Free, Sans, Bold, Oblique, 12pt.
tft.drawString("Temp",00,00);
tft.drawString("Humi",130,00);
tft.drawString("Moist",252,00);
tft.drawString("Pump",230,110);
tft.drawString("UVLed",48,110);
// tft.setCursor(120, 200, 4);
tft.setTextColor(TFT_GREEN, TFT_WHITE);
tft.drawString("Watero",100,200,1);
// delay(500);
tft.setTextColor(TFT_BLUE, TFT_BLACK);
Step 3: setup adafruit io platform :
- go to https://io.adafruit.com/ and make an account
- for more details you can follow this rich tutorial from Seeed Studio using the Wio terminal which will explain the usage of MQTT protocol and the Adafruit Io platform too step by step :
- install the "adafruit mqtt " library for both Wio terminal and Esp32
- for the full code for both Wio terminal and Esp32 check the attached code.
Comments