WiFi Enabled Soil Moisture Sensor

Combining the D1 Mini and Blynk to create a wireless Soil Moisture Sensor…

This small portable sensor can be used to alert you to the moisture condition of your plants. In the future it can be combined with a water pump to create a fully automatic garden system.

_MG_7852

To begin you will need to download and 3D-print the 3 separate parts available via thingiverse.

You will need the following components:

WeMos D1 Mini
3.7V 14500 Li-ion Battery
Capacitive Soil Moisture Sensor
D1 Mini Battery Shield
WS2812 RGB LED
1 x AA Battery Holder

Connect everything together using the following schematic:

Schematic.png

The shield can be connected directly to the D1 mini. The breadboard is used above for reference only and components should be soldered and crimped together in order to facilitate positioning inside the printed housing.

Remember to connect the RST pin to D0 in order to enable sleep mode.

The final assembled device should look similar to the image below:

DSC00734.jpg

Download the Blynk App to your smart phone/device and create a new project based on the following:

Screenshot_2018-12-16-22-42-33-140

Upload the sketch to the D1 Mini using the Arduino IDE. Edit the sketch to include reference to your WIFI SSD and password as well as your unique Blynk authentication token.

Insert and charge the battery and watch the data roll in…

Use the sliders in the app to adjust the threshold at which the dry/wet alerts are activated. The sketch can be further customised if your sensor needs it as well as for things like the length of time to sleep.

Arduino Garden

So I started work on my next project today, an automatic garden watering system and monitor based built using Arduino. My plan is to create a system that can:

  • Monitor basic parameters such as temperature and humidity
  • Detect when soil moisture is low and water automatically from a tap or reservoir
  • Be accessible and controllable via the internet
  • Alert when reservoir is low, excess temperature etc.

With the following additional features depending on how much success I have:

  • Collect excess water and recycle back to reservoir
  • Be powered using batteries recharged from a small solar panel

I started out using an Arduino Uno and a cheap 5V motor in order to determine if it could be powered from the USB alone and provide sufficient power to pump water over a distance of approximately 1m. I connected as follows:

sketch1-1024x919.jpg

Once this was successfully pumping water, I attached an ESP-01 and configured it to connect with Blynk to enable remote control.

This enabled me to start the pump from my phone but unfortunately Blynk would then suddenly disconnect and I would have to recycle power to the ESP-01 to get it going again. So thinking this may be due to the fact the ESP devices are very sensitive to their supply I am attempting to isolate it from both the Arduino and the pump using an external power supply and a relay switch.

DSC00376

I’ll let you know how I get on…