Close

On soil moisture sensors...

A project log for Magnificent Moisture Management

I've got a balcony, tomatoes and a micro controller

michael-haasMichael Haas 10/18/2014 at 18:040 Comments

Too dry and your plants will wilt. Too wet, and the roots will rot. So you're going to need a moisture sensor.

The standard method in the hobbyist community seems to be a resistive sensor. You take two electrodes, e.g. two nails, put them in the dirt and measure the resistance between the electrodes. This approach has several problems. First, the resistance measurement is temperature dependent and soil temperature is not very stable, especially outside. So you to measure the temperature and correct for that. Second, electrolysis will happen and one electrode will corrode. Basically, you build a machine that generates random resistance readings and rust.

No, it's not that bad, of course. Resistive sensors have been successfully used by many people. For example, the Cheap Vegetable Gardener described such a sensor five years ago. If you look around, you can even find some ready-made gold-plated electrodes for the task on ebay. Gardenbot also describes a setup which avoids electrolysis.

A capacitive method is much more elegant. You basically make a capacitor where the soil becomes the dieletric medium. If the soil becomes wet, the dielectric properties of the water dominate and the capacity of the capacitor increases. This method is much more reliable, although it still requires some calibration. Micah J. Waldstein has a some nice blog posts on his own "grow with arduino" experience where he works with capacitive sensing.

Now, where can you get one of these capacitive guys? Miceuz from the Wemakethings.net hacker space in Lithuania designed a capacitive soil moisture sensor. He calls it "chirp!" and he even has a detailed writeup on the design (1, 2). The best thing.. no, wait, the best three things: both hardware and software are open source and it's easily hooked up to a micro controller via I2C. Actually, the best thing is he sells these pre-built on tindie for a great price. There is a standalone version which goes "chirp!" and a sensor-only build which acts as an I2C slave.

That's it! Note that I did provide some additional links on different sensor types and implementations. During my research, I found lots of other nice sensor projects. So, if you need even more information, just hop over to your favourite search engine.

Discussions