I recently received a bonsai tree as a gift and I was a little concerned about killing it from forgetting to water it regularly. I thought this would be a good chance to dust off my Twine unit and use the moisture sensor to tweet me when it needed a drink.
I was inspired by this post by Jarod Reyes to think about how I could bring the internet of things into my garden. I had purchased the Twine a year or so ago, with the full sensor pack, but in truth had never really gotten around to building a worthwhile project with it. So with renewed motivation to try and hack something together this weekend I went and found the Twine, dusted it off and set about building a soil moisture monitor for my bonsai.
It had been a year or so since I had last turned on my Twine, so I grabbed some fresh batteries and did a full firmware update. Once everything was back up and working, I set about configuring some rules for the moisture sensor using the Twine management portal.
I wanted to give this project a bit of a personality, so firstly I set up a Twitter account for my bonsai at @devinsbonsai. I wanted the Bonsai's account to tweet my personal twitter account @devinmancuso when the soil was dry and after it was sufficiently watered. I then authenticated the @devinsbonsai account with the Twine app so the Twine had permission to post through the newly created Twitter account.
I then setup a few rules for the Twine and the moisture sensor. The Twine would check the status of the moisture sensor every 8 hours. If the soil is dry for more than one hour, the moisture sensor will report a dry status and the bonsai Twitter account will fire off the following tweet reporting it needs to be watered.
As soon as the moisture sensor has been wet for 1 second, the Twine will fire off a tweet reporting that it has been watered. There was no real need for this one from a logic standpoint, but I thought it would be fun for the plant to reply after being watered.
Below is a screenshot of how I set up the Twine ruleset.
Once all the rules were set up and tested (using a glass of water), I moved the sensor into the Bonsai.
I stuck the Twine box to the side of the pot using some blue tack. The Twine box and moisture sensor are not completely waterproof, luckily my Bonsai sits under a balcony so it's protected when it rains. However, I might look into a waterproof solution if I want to leave the bonsai outside with no cover. I've heard a softdrink bottle cut in half is a good DIY option, so that'll be my next little enhancement.
Note: the moisture sensor that comes with the Twine is quite limited and as such it's not particularly appropriate as a soil moisture sensor. This project was more of a fun proof of concept for me to play with, the next step would be replicating the system using an Arduino board and a dedicated soil moisture sensor.