Automatic plant watering system
Read the analog moisture level, compare it to a calibrated dry threshold, and switch a relay or MOSFET to drive a small pump so a plant waters itself.
A corrosion-resistant capacitive probe that reports soil moisture as a single analog voltage.

The Capacitive Soil Moisture Sensor v1.2 measures how much water is in soil by sensing the soil's dielectric constant rather than its electrical conductivity. An onboard oscillator (a TLC555 CMOS timer on the v1.2 revision, replacing the NE555 used on earlier boards) drives the sensing area of the PCB, and the circuit converts the resulting capacitance into a steady DC voltage on the AOUT pin. Because the probe never passes current directly through the soil, its sensing surface does not corrode the way the exposed metal prongs of cheap resistive sensors do.
The module runs on 3.3V to 5.5V and exposes just three connections: red VCC, black GND, and yellow AOUT. The output is a plain analog voltage that moves inversely with moisture: drier soil reads a higher voltage and wetter soil reads a lower one. Powered at 3.3V, a typical unit sits near 3.0V in dry air and drops toward 1.5V when the tip is submerged, which maps comfortably onto a microcontroller's 10-bit ADC.
There is no digital interface, no I2C address, and no library protocol to speak of. Any board with an analog input, such as an Arduino Uno, Nano, or an ESP32, can read it with a single ADC call. The tradeoff is that raw readings depend on soil type, packing, and unit-to-unit variation, so the sensor must be calibrated against known dry and wet references before its numbers mean anything.
| Pin | Function | Type |
|---|---|---|
GND Black / GND | Power | Power in |
VCC Red / VCC | Power | Power in |
AOUT Yellow / AOUT | Analog soil moisture voltage | Digital output |
Verified from the Tinkered component library · Generic HW-101 / DFRobot-style module.
The Capacitive Soil Moisture v1.2 connects to any of the microcontrollers supported in Tinkered. Mind the 3.3 V logic level on 3.3 V boards.
Only the lower sensing region is meant for soil. Pushing the probe in past the max line, or leaving it in wet soil uncoated, lets moisture reach the traces, header, and timer chip, causing drift, shorts, and eventual corrosion.
Unlike a resistive fork sensor, this probe's output voltage is inverse to moisture. Dry soil gives a higher voltage and ADC count; wet soil gives a lower one. Getting the direction backward inverts every threshold in your sketch.
Raw values vary with soil type, compaction, supply voltage, and even between two of the same modules. Copying someone else's dry/wet thresholds usually produces wrong percentages. Always take your own air and water reference readings.
Despite the exposed board looking sealed, the thin solder-mask ink is not durable in wet soil. Units left in pots for months often corrode along the sensing edge unless the lower section is coated with epoxy or heat-shrink.
Leaving the sensor energized around the clock adds unnecessary corrosion stress and self-heating; power it only when sampling. Also, powering at 5V while the ADC references 3.3V (or vice versa) skews the mapping if you forget to account for it.
Read the analog moisture level, compare it to a calibrated dry threshold, and switch a relay or MOSFET to drive a small pump so a plant waters itself.
Show the moisture percentage on an LCD 1602 or OLED and light an LED or sound a piezo buzzer when the soil crosses the dry setpoint.
Pair the sensor with an ESP32 or ESP8266 to log soil moisture to a dashboard or phone notification, tracking trends across a garden bed or greenhouse.
Sample the analog output at intervals and record it to an SD card or RTC-timestamped log to compare drying curves between different soils or watering schedules.
Drop the Capacitive Soil Moisture v1.2 into a circuit, write firmware, and simulate it in your browser, then deploy to real hardware. All in one editable Tinkered project.