The dead Cactus - part 1
As the headline indicates, my cactus died. I like having plants. It simply just adds something. I guess it could be related to having nature present in the living room in the middle of a concrete jungle. However if I cannot even manage to keep a cactus alive, what good does it anyways?
I have seen people making some automated irrigation system for watering their garden plants. Is also no secret that I am super lazy, so I like everything automated, tech and a good mental challenge. It need to scale it down for my livingroom.
I went to Aliexpress and I quickly found a 5V waterpump. This is perfect, it could get power from my Raspberry Pi. I also found some moist sensors and a relay to turn the pump on and off. Just as I was about to press “Buy”, I actually found a package with 4 smaller pumps, hoses, sensors and relays. Total price of $14 including shipping. I chose the cheaper solution to start with. Proof of concept is always important for me before I go for the perfect solution. I paid a little extra for shipping, so hopefully it will be here soon.
One thing I need to keep in mind: I have read that cheap moist sensor can corrode and this can/will kill the plant. I need to watch out for this. Luckily a more expensive sensor is still less than $5.
The pumps also seem to be smaller and require less voltage. I am sure this is ok since it is not meant to pump gallons of water and I expect to have a water bottle nearby.
Since I need a water bottle I must remember, that this too can run out. I already get bored thinking I need to check on this every now and then. I could make some tests. See how much water the pump can push through in X minutes or seconds. Then record the amount of time the pumps are on and calculate mathematically the amount of water left in the bottle. Again, the laziness kicked in and I bought a switch that can tell me when to fill the water bottle. Easy peasy lemon….
The basic idea: The sensor registers if the dirt around the plant is dry. If it’s dry a signal will be send to the Raspberry Pi, that turns on the water pump, and water goes to the plant, giving moist to the dirt. Once the sensor registers moist, I must assume there is enough water to keep the plant alive. Another approach could be to turn on the pump for 2x or 3x 10/20/30 seconds and measure the moist in the dirt. Or is it conditioned by the plant? Does it only need a bit of water? Does it need to be overly soaked? – I need to study my flora a bit for this.
I will connect the pumps to my Raspberry Pi’s one 5V pin. I will have to connect them in parallel connection. Since there is not much sunlight in my windows I might need the other 5V outlet for a growth lamp.
It is however important for me to keep in mind, that only one pump can run at the time. Otherwise there will not be enough power to run the pumps and water the plants. I assume the sensor would keep reporting the dirt is dry. The pumps would basically pump them self to death. Not a good idea.
Right now I am just waiting for different parts to arrive. Creating the program to run it all will hope fully not be a problem. I hope to be able to set it up in one Saturday afternoon.
What the program must do:
- Register if the dirt is dry or moist
- Control the relay that starts and stop the water pumps
- Calculate / measure the amount of water send to the plants
- Save timestamp for watering + amount in my database for display in my homehub dashboard
- Send me an email, when the water bottle is near empty. Perhaps I need to switched to receive two reminders..
To be continued