How do I add the soil-moisture sensor to domoticz?
-
@hek Where is the question to your answer hek? ;) Can't see it here.
But corrosion do to the current in the sensor might be the reason for my dead sensor. Any ideas how to avoid that on that kind of cheap Soil Moisture Sensors from the project page?PS I guess powering the sensor over a pin of the arduino (or some kind of transistor) would make it possible to disable the sensor when not measuring. That might help?!
-
Basic information are also on the project page. I was using the same kind of sensor (cheap one from ebay). I seemed to work very well for about one week but then suddenly it started to send back only one value.... when I took the sensor out of the soil I saw that the sensor (at least one leg) had mold on it. Has anyone seen such a problem? Any ideas how to prevent that?
-
Great idea hek, I think that is the problem. But the sketch you posted uses a different sensor, doesn't it? There is something about:
* Connection: * D6, D7: alternative powering to avoid sensor degradation * A0, A1: alternative resistance mesuringAnd a link to different sensor. The cheap kind that I am using only has two connections for power and an analog and digital pin. I don't see how you could be alternating power here...
But perhaps it helps if the sensor isn't constantly powered on but only for measurements.
Does anyone else have a solution for this? -
Maybe a bit late. But the soil moisture sketch was the first one I brought into production by soldering it on a PCB. I added it to Domoticz as a motion sensor, not as a switch. And it's working great. If the motion sensor is telling that there's motion, it means the plants aren't thirsty. If there's no motion than the plants need some water. I even let Domoticz send a message to my mobile phone when the plants are thirsty ;-). I keep forgetting to give my plants water on a regular basis, so this sensor is really helpful.
-
Hi @TheoL
Motion sensor and Switch (and also the soil moisture sensor) work the same way in Domoticz. Its either 1 (ON/Motion/Wet) or 0 (Off/No motion/dry). -
Yes, @epierre should clarify what sensors used and how it should be connected in the sketch.
If a new sensors type is used we should probably keep the old example and create a new one for this.
@hek said:
Yes, @epierre should clarify what sensors used and how it should be connected in the sketch.
If a new sensors type is used we should probably keep the old example and create a new one for this.
Well it is here in the sketch: " Required to interface the sensor: 2 * 4.7kOhm + 2 * 1N414"
but it was better in the post: http://forum.mysensors.org/topic/514/soil-humidity-and-temperature-sensor-watermark-davis-granular-matrix-sensor/2
and yes it works with two connectors this way !
@hek I'm not in the list ;-) https://github.com/mysensors/Arduino/graphs/contributors
-
@hek said:
Yes, @epierre should clarify what sensors used and how it should be connected in the sketch.
If a new sensors type is used we should probably keep the old example and create a new one for this.
Well it is here in the sketch: " Required to interface the sensor: 2 * 4.7kOhm + 2 * 1N414"
but it was better in the post: http://forum.mysensors.org/topic/514/soil-humidity-and-temperature-sensor-watermark-davis-granular-matrix-sensor/2
and yes it works with two connectors this way !
@hek I'm not in the list ;-) https://github.com/mysensors/Arduino/graphs/contributors
Well it is here in the sketch: " Required to interface the sensor: 2 * 4.7kOhm + 2 * 1N414"
but it was better in the post: http://forum.mysensors.org/topic/514/soil-humidity-and-temperature-sensor-watermark-davis-granular-matrix-sensor/2
and yes it works with two connectors this way !So this works with the sensor I linked above (= the one in the picture above)? I though changing the voltage way would destroy the sensor..
My goal is to have the sensor in soil for years though. Even if I turn it off while not measuring it might break I guess. -
Anyone? Because I really want to use the sensor but I don't really get the posts her ;)
-
@epierre did an update on the sketch which reverses polarity to help avoiding corrosion.
And this sketch is supposed to be connected as this? :)
Edit: correct link is http://vanderleevineyard.com/1/post/2012/08/-the-vinduino-project-3-make-a-low-cost-soil-moisture-sensor-reader.html