Objective
Water a plant automatically when the soil gets dry, and show moisture on a display.
How it works
The capacitive probe outputs a lower voltage as soil gets wetter. The Nano reads it, compares it to a threshold you calibrate, and switches the pump through the relay for a few seconds.
Components you'll need
| Component | Qty | Availability | Price | |
|---|---|---|---|---|
Arduino Nano | ×1 | In stock | $6.17 | |
Moisture Sensor | ×1 | In stock | $1.29 | |
Mini Submersible Water Pump | ×1 | In stock | $0.89 | |
| 1-Channel Relay Module | ×1 | In stock | $0.79 | |
| Jumper Wire Set (120 pcs) | ×1 | In stock | $2.99 | |
Breadboard medium | ×1 | In stock | $0.99 | |
0.96" OLED Display (I2C)optional | ×1 | In stock | $3.99 | |
| Bought one by one | $13.12 | |||
All of these come in Smart Garden Kit.
Circuit & connections
The full wiring diagram and pin-by-pin connections.
Code
The complete, tested sketch (13 lines), ready to upload.
Step-by-step instructions
4 illustrated steps:
- 1Calibrate the sensor
- 2Wire the relay and pump
- 3Upload and test
- 4Install
Troubleshooting
Fixes for the problems makers hit most often on this build.





