I have soil Moisture sensor inserted into the pot soil, wet in state. (not too damp) and soil moisture sensor is connected to Arduino Mega 2560.
This is a simple arduino project for a soil moisture sensor that will light up a LED at a certain moisture level. It uses Arduino Duemilanove microcontroller board. Two wires placed in the soil pot form a variable resistor, whose resistance varies depending on soil moisture.
This is the soil moisture sensor I am using:
Soil Moisture Sensor VCC is fed by 4.95 coming from Mega's 5 volt power out and soil moisture signal is connected to A0.
below are the readings
I got three kind of readings of the sensor:
pot1_soilMoisture
reading from 825 to 833 is when the sensor was dipped in water.pot1_soilMoisture
reading from 463 to 190-1023 is when soil moisture sensor was in air.pot1_soilMoisture
reading from 604 to last 921 is when soil moisture sensor is in soil. The soil is moist/wet.
I don't understand how to be definitive state of soil with such values?
Ciasto piekarzCiasto piekarz29611 gold badge99 silver badges2121 bronze badges
1 Answer
I had this same problem when I began experimenting with soil moisture readings. I noticed that the readings from the sensor can vary widely when not hooked up correctly, or when other nearby objects are somehow interfering.
For instance when I put a SparkFun breakout similar to yours in dry soil and continuously take readings every 50ms, the signal oscillates from 0 to 50, and simply touching the soil with my finger can affect the signal due to the electricity in my body. If you have a metal pot on a metal table, that could be affecting your readings. There's a lot to consider!
However, once I water the soil and let it soak in, the reading generally becomes much more stable. Below I included a real-time plot using a plant I watered about 24 hours ago. Here's how I set up my soil moisture sensor, including code. The readings are taken every 60s and the plotter repeats the old reading until a new one is taken. There's very little deviation when all connections are secure and the soil moisture is evenly distributed.
In general, the specs for the sensor will inform you on what kind of signal to expect. Based on your sample data I suspect yours is a 10-bit signal from 0-1023, so 800 range means the soil is quite moist. If you just watered the plant, then the water content around the sensor will change as it seeps through the soil, leading to fluctuations when measuring. Give the soil a few hours to absorb the moisture and try measuring again.
Chris RuppelChris Ruppel
Not the answer you're looking for? Browse other questions tagged arduino-megasensors or ask your own question.
I have soil Moisture sensor inserted into the pot soil, wet in state. (not too damp) and soil moisture sensor is connected to Arduino Mega 2560.
This is the soil moisture sensor I am using:
Soil Moisture Sensor VCC is fed by 4.95 coming from Mega's 5 volt power out and soil moisture signal is connected to A0.
below are the readings
I got three kind of readings of the sensor:
pot1_soilMoisture
reading from 825 to 833 is when the sensor was dipped in water.pot1_soilMoisture
reading from 463 to 190-1023 is when soil moisture sensor was in air.pot1_soilMoisture
reading from 604 to last 921 is when soil moisture sensor is in soil. The soil is moist/wet.
I don't understand how to be definitive state of soil with such values?
Ciasto piekarzCiasto piekarz29611 gold badge99 silver badges2121 bronze badges
1 Answer
I had this same problem when I began experimenting with soil moisture readings. I noticed that the readings from the sensor can vary widely when not hooked up correctly, or when other nearby objects are somehow interfering.
For instance when I put a SparkFun breakout similar to yours in dry soil and continuously take readings every 50ms, the signal oscillates from 0 to 50, and simply touching the soil with my finger can affect the signal due to the electricity in my body. If you have a metal pot on a metal table, that could be affecting your readings. There's a lot to consider!
However, once I water the soil and let it soak in, the reading generally becomes much more stable. Below I included a real-time plot using a plant I watered about 24 hours ago. Here's how I set up my soil moisture sensor, including code. The readings are taken every 60s and the plotter repeats the old reading until a new one is taken. There's very little deviation when all connections are secure and the soil moisture is evenly distributed.
In general, the specs for the sensor will inform you on what kind of signal to expect. Based on your sample data I suspect yours is a 10-bit signal from 0-1023, so 800 range means the soil is quite moist. If you just watered the plant, then the water content around the sensor will change as it seeps through the soil, leading to fluctuations when measuring. Give the soil a few hours to absorb the moisture and try measuring again.
Chris RuppelChris Ruppel