How to Build a Soil Moisture Sensor Circuit with an Arduino
In this project, we are going to build a soil moisture sensor with an Arduino microcontroller.
A soil moisture sensor, also called a hygrometer, measures the amount of moisture, or water, in the soil.
Therefore, we can tell whether the soil has enough moisture or not. So it is a good diagnostic tool for caring for plants of all types.
If the soil is extremely dry, then you will know the plant should be watered.
If the soil is very moist, then you will know that it does not need to be watered.
The soil moisture sensor we will build is simple to connect because we’re going to use a prebuilt module. This means everything is already included. We simply have to connect the output terminals to a microcontroller such as the Arduino.
If you type in ‘Arduino Soil Moisture Sensor’ into ebay, you will see the complete type of sensor needed to build this circuit.
The sensor has 4 terminals for connection, Vcc (for power), GND, Analog output, and Digital output.
Vcc and ground are how the sensor gets the power it needs to operate. Here we connect 3.3V-5V of external power.
Analog output shows the value the sensor is reading which correlates to the amount of moisture it detects. The analog value varies from 0 (very wet) to 1023 (very dry). So if the soil is very dry, the analog output will have a very high reading. If the soil is we, the analog output will have a very low reading. This is how we will know whether the moisture content of the soil.
The Digital output simply goes high or low. Since we are working with a microcontroller that can interpret analog signals, this is more precise than digital signals, so we will not connect the DO pin. If we weren’t using a microcontroller, then we probably would have to use DO instead of AO.
A soil moisture sensor, again, is a very useful tool for plant care and maintenance.
- Soil Moisture Sensor Module
The soil moisture module has 4 pins.
The table below summarizes these pin connections.
|Soil Moisture Sensor
|Vcc||Connects to 5V terminal|
|GND||Connects to GND terminal|
|AO||Connects to an analog terminal (A0-A5)|
Logic Probe Circuit
For more detail: How to Build a Soil Moisture Sensor Circuit with an Arduino
JLCPCB – Prototype 10 PCBs for $2 + 2 days Lead Time
China’s Largest PCB Prototype Enterprise, 300,000+ Customers & 10,000+ Online Orders Per Day
Inside a huge PCB factory: https://www.youtube.com/watch?v=_XCznQFV-Mw
This Post / Project can also be found using search terms:
- soil moisture sensor arduino pdf download
- soil moisture content project using arduino pdf
- how to connect soil misture to xbee pdf