Select Page

This post includes Python code that will trigger the water pump to turn on when the soil sensor detects that the soil in the plant is dry.

Raspberry Pi Water Pump

The pump will turn on pulling water from the tub through water lines up to the plants. The code also detects when the soil sensor is wet and will trigger the pump to turn off. This assures the plants are only watered when the plant soil is dry and not over-watered when the soil is wet. Download Soil Sensor Code

For those reading this who want to make their own Christmas Tree Circuit, following is where you can get the supplies