Automated watering of potted plants with Intel Edison... A Moisture Sensor detects the low moisture content of soil and activates the water pump or the solenoid valve which controls the flow of water. When the required water is pumped to the plants, the sensor automatically stops the pump / solenoid valve. It is a repeat process.

This is one of my original proposals submitted to Intel IoT Invitational where the Instructables HQ team seeded about 300+ community members with specially bundled kits under different themes. I was awarded a kit under "Environmental & Agriculture".

The Intel Edison is based on Arduino Uno. I was new to Arduino and Intel Edison. So, when the first batch of recipients were announced and I got an email from instructables that I was wait-listed, I felt relieved. The reason being that I need not get into the process of something new which may take a month or two to learn even the basics. But when I got another mail that my proposal has been selected under "Environmental & Agriculture" I was happy. I am a learner, so Immediately I started my learning process, browsing through related websites, forums and collecting resource material. It took me almost two months to come to a beginner's level and I can proudly say that I can do small projects with Intel Edison and develop my own simple Arduino code for such projects.

I have tried my level best to make this instructable as simple as possible with multiple steps explaining everything involved in this project so that anybody can replicate and use it in their home.

Regarding the parts and materials required, instead of posting all of them in one step and scaring away the readers, I have broken down the material requirement and combined them separately with the relevant steps.

Please watch the video and go through the instructable. Your comments and valuable suggestions for improvement are most welcome...

Step 1: Setting Up Intel Edison

Setting Up Intel Edison

The first time you got your Intel Edison, you need to assemble and set up the necessary device drivers and the programming language of your choice.

  • Assemble Intel Edison with the Breakout Board
  • Install the necessary Device drivers
  • Install Flash Tool and Flash the Edison
  • Set up your preferred programming language

You need two numbers of Micro USB 'B' to Type 'A' Cables and a 12 Volt DC power adapter suitable for the power supply in your country (110/120 or 230/240 volts). Make sure that the rated power of the adapter is minimum 1.5 ampere and the inner pin is the positive pole.

Easy to follow step-by-step clear instructions on getting started with Intel Edison board is provided in the following link :


Please follow these steps to assemble, install necessary device drivers, flash Edison Board and installing the Programming language of your choice. I preferred Arduino as it is very easy to learn and also there are lots of sample codes for the sensor modules available online. Sometimes the flash tool may fail and you may need to flash the board manually. For this project we do not require to setup the serial terminal and wi-fi.

Once you finished installing the Board, please remember to note down the Virtual Com Port number and the USB Serial Port number from the Control Panel - Device Manager - Ports (COM & LPT) menu. You can see in the last picture of my Device Manager screen-shot, that the Virtual Com Port number is 21 and the USB Serial Port Number is 22.

If you have any problem or doubts please post a comment here and I will be happy to help to the best of my knowledge.

Very well documented and executed.
<p>Dear Antony , </p><p>i am from India , Tamilnadu , i am interested in growing bonsai plants , i seen ur instruction on Air layering its amazing i just loved it , pls ping me @ kishorejoshuva27@gmail.com , i am 22 years old and love to make home gardening , i wanna to ask u more ques pls pls ping me sir .</p>
I am also from Tamilnadu in Theni District. Please give me a message whenever you are coming to this area.
<p>Very detailed and understandable project thank you!</p>
Thank you...
Sometimes one of the most difficult projects seem so easy to make. This is just because of the perfect and detailed documentation by the author. This is what happening here :)<br><br>I don't believe that you are able to grasp so much about electronics in so less time and write such epic instructables! I salute the efforts you have put in making and presenting this project. Hope that you win :)
Thank you Saiyam... I am still not able to make circuits with PNP type transistors. Hope you may help in this
<p>Sir I can help.Just tell me what you need to do with PNP type transistors.<br>I can tell you the basics of PNP and NPN and when to use one.<br>Thank You!<br>And Congratulations! </p>
<p>thank you <a href="https://www.instructables.com/member/rjawale" style="">rjawale</a>... can you please tell me how I could use PNP type transistor, say TIP 127 in place of TIP 122 in the circuit I made here ?</p>
<p>yes sir.<br>PNP transistors are opposite of NPN. In case of an NPN transistor, a +ve voltage(greater than 0.7V) applied to base turns the transistor to ON state i.e the load in the collector will switch on.Whereas in case of a PNP transistor a low voltage like -ve or ground will turn the PNP transistor ON. <br>Also the biasing techniques change in case of PNP. You have to reverse the polarities in the NPN circuit and change the transistor to PNP.<br>Here's the circuit for both the transistors-<br> PNP transistors are hardly used alone. In case you want some circuit to trigger when a low pulse is applied like in case of many burglar alarms, we use PNP.<br>Also they are used along with NPN transistors in a power amplifier configuration called as complementary symmetry push pull power amp.<br>And the TIP transistors you're are using in your project are darlington pairs. Darlington pairs are two transistors in common collector config. in which you get a very high current gain. Darlington pairs can be NPN and PNP type both. Usage is same as a single NPN or PNP transistor as I have explained above.<br>Why use Darlington pairs?<br>Applications like speaker drivers,motor drives need high current. because they work on electromagnetism principle. They need more current to drive rather than voltage. So we want current to be amplified. And common collector amplifier is used for current amplification. Darlington pair is a cascaded common collector config. which has very high current gain and unity voltage gain.<br>I hope you got it. You can again ask me if you want more details on it. I will send a personal message.</p>
<p>thank you <a href="https://www.instructables.com/member/rjawale" style="">rjawale</a> for your explanation and the circuit diagram. I will go through it and come back to you in case of any clarifications needed</p>
<p>Hi - I'd like your plumbing setup - really need something like that for my plants :) <br><br>I've never seen a diode used like that before though - the current drawn from the pin might be too high for the Edison (you could test with a multimeter in series - should ideally be way way less than the max of 20mA) - normally a resistor would be used there (1K or slightly larger) - and as you are switching a motor you would normally then place the diode across the motor terminals. Like this:</p><p></p><p>https://www.ez-robot.com/Community/Forum/posts.aspx?threadId=3050</p><p><br>The spare PNP transistor you are trying to find a use for is not really suitable for these types of single transistor applications - depending on the circuit you use you may have issues with the maximum voltage motor you can use (5v in this case) or getting the motor to switch off (some more info here: <a href="http://www.w9xt.com/page_microdesign_pt8_pnp_switching.html">http://www.w9xt.com/page_microdesign_pt8_pnp_switc...</a> )<br><br></p><p>If you are short of transistors, you can salvage lots of great power Transistors - including really useful MOSFET transistors from old PC power-supplies if you disassemble them safely.</p>
<p>Thank you for your suggestions and links provided. I will certainly go through them. I am new to electronics and followed the circuit from some documents I downloaded from the net.</p><p>I have lots of old computer parts like power supplies and all. I will try to salvage power transistors from them as suggested by you. I also have MOSFET Transistors (IRF 530) with me. Will try to use it in my future projects.</p>
<p>Your hard work got you in the finals! Congratulations :)</p>
thank you Saiyam...
<p>Congratulations Sir.</p>
<p>thank you deba, congratulations to you too...</p>
<p>Nice basic approach, however, it does not scale well to additional plants. Reason being is that pressure drops across the line will cause a different flow rate at each discharge point. There are equations to solve what the flows at each discharge point will be, however, your basic approach of controlling the pump 'on time' will cause different amounts of liquid in each planter for a given on time. There are at least two solutions: a) vary the diameter of the pipe between each planter to ensure the same volume of water gets to each planter, b) use drip emitters at each discharge point to ensure a constant volume. Drip emitters are sized in gallons/hr, and range from 0.5 gph to 20 gph. The line requires a minimum of 20psi (I believe...dont recall exactly) for the emitters to function at their rated discharge rate. You can try the varying pipe diameter approach but changing the topology will cause you to (most likely) resize the pipes. The emitter approach is more practable and flexible. </p>
<p>thank you... I experienced the problems of all plants not getting the water in equal amounts. As I mentioned in Step 27, I have reduced the openings at different points so that all plants get equal amount of water. However, the drip emitter as suggested by you seems to be a better option</p>
Hi sir....i m indian @ tamilnadu...how your state ?? I need ur friendship sir...my mail <br>mynamebalakrishnan@gmail.com
<p>Hello, I am also from your state. Since you are following me you can get updates of my new instructables in your page</p>
<p>Congratulations, great Instructable ... If you intend to actually use this system while unattended, I strongly recommand to add error detection and safety actions !<br>You could do a &quot;what if&quot; review for typical events (sensor no longer responding, water hose no longer in pot, etc ...) with actions (timer, ...) to avoid unlimited flow of water in your pot / balcony / home ... :-(</p>
<p>thank you very much... I will do reviews as suggested by you as they are very important for the system to work efficiently...</p>
<p>Great instructable !!!!</p><p>I have a question, though : shouldn't you take measurements or soil moisture every 20-30 seconds to give some time to let the soil absorb water ? <br>And cycle through sequences like : measurements / watering for X seconds / timeout to let the soil absorb water - measurements (repeat until measurements reach 700)</p>
<p>Thank you <a href="https://www.instructables.com/member/AlienSKP" style="">AlienSKP</a>...</p><p>Though I have not explained it in step 5, I did exactly as you suggested, not every 20 to 30 seconds, but about 5 or so seconds. I took screen shots of intermediate readings in Serial monitor also but did not post here as they may confuse the reader</p>
<p>OK cool ! I was looking the same kind of automated system to water a garden next spring, I might use your code ! <br>the only difference with what I try to achieve is the size (way bigger) and use of a solenoid valve instead of a pump and the use of a battery/solar panel as main power.</p><p>Thanks for your inspiration !!! </p>
<p>thank you, I am also on the same idea as yours, using a solenoid valve in my next project with MediaTek LinkIt One Board. I have already bought one and tested. This time I will connect it to a permanent water outlet nearby as shown in pictures here</p>
<p>This is cool !!!! you rock</p>
<p>thank you... you are very kind</p>
<p>Great instructable!<br>I can however see a potensial &quot;problem&quot; in your setup...<br>You're using 1 pump to water 3 plants, and if they're different plants they'll probably consume water at different rates. It's a risk that the two plants without sensors will dry out or get too much water... ;-) <br>But it's great starting point!</p>
<p>thank you, yes you are right it's a great starting point. As I mentioned in Step 27, the first plant used to get more water than the other two. So I plugged and adjusted the water flow so that each plant gets equal amount of water. I will monitor the plants and make necessary adjustments in future also. </p>
<p>Neat project and good job on the Instructable. I've played around with a small drip irrigation system at home and ended up doing my own moisture meter but it is still a work in progress. Two thoughts... </p><p>a) If you have a spare diode, it wouldn't hurt to place it across the pump motor to reduce reverse EMF.</p><p>b) I put an inch or so of shrink tubing over the very tops of the two moisture probe tips. It was my hope that by doing that, when the probe is pushed into the soil, also allowing some of the shrink tubing to be covered, there would be less variability in the readings with respect to the probe placement depth (same contact area is always exposed).</p><p>If you end up using the moisture probe for more than a season, you will probably have to replace it since they are expendable. Knowing that, I made stainless steel probe tips for my sensor but even after one season they were toast. The DC sense current caused them to corroded. One tip was like swiss cheese and thinner than tin foil. </p>
<p>Thank you <a href="https://www.instructables.com/member/c.r.h." style="">c.r.h.</a>...</p><p>a) I will do as suggested by you. I got spare diodes with me and I will do a new circuit for future use.</p><p>b) I have covered the electronic parts in a small plastic case to prevent accidental spray of water and pushed the exposed portion of the moisture probe in soil.</p><p>You are right about the moisture probes getting damaged due to prolonged exposure. I will use this system only when we are away from home for an extended period of time. Otherwise we water the plants manually as the plants need watering twice a day and about one liter of water is sufficient for all three plants one time.</p>
<p>It's fun stuff. I use a Linux computer to trigger watering cycles because it was my goal to never have to touch our potted plants for the whole summer. I did have one 'ops' though. During a watering cycle, I had to reboot the computer, a very rare occurrence. Not knowing that the plants were being watered at the time, I only found out hours later. I got an ear-full from my special someone. Live and learn. For safety, maybe a delay-off circuit for the solenoid since mine is on city water.</p>
<p>I did a similar project using simple modules and handmade pump called &quot;Watering houseplants&quot; (text on Russian language)</p><p><a href="http://vip-cxema.org/index.php/home/raznoe/282-sistema-poliva-komnatnykh-rastenij" rel="nofollow">http://vip-cxema.org/index.php/home/raznoe/282-sis...</a></p>
I saw your project. Unfortunately I could not read the contents as it is in Russian
<p>Great, but I agree with the other commenters that using an Intel Edison for this is serious overkill. The same can be done with An Attiny13, or even an opamp.<br><br>You will find that the sensor probably will be eaten away quite quickly by electrolytic corrosion.<br><br>As you are using an Intel Edison that has plenty of ports left, consider adding a variabel resistor that allows you to tune the level where the soil is considered 'dry'<br>You now have hardcoded that value in your program and you will find that over time that value will not be accurate anymore due to fertilizer ions being in the soil and due to corrosion of your sensor<br></p>
<p>thank you very much... I agree with you that Intel Edison is an overkill. I got the Grove Sensor modules and the Intel Edison as a give away from instructables under the theme Environmental &amp; Agriculture. So I have to make the project using Intel Edison.</p><p>Secondly, I will be using this set up when we are away from home for an extended period only. you can simply disconnect the outlet pipe from the water pump and take everything inside for safe keeping. If you look at the photograph in the concluding step, you can very well see that I have an additional pipe line running from a near by water outlet (Extreme Left in the picture). We will normally use this for watering the plants.</p><p>I am new to Intel Edison and Arduino. It took me more than two months going through so many documents and resources available online to make this instructable. So, regarding adding a variable resistor to the setup, if you could point out some reference material from the net that will be very helpful</p>
<p>In fact, if you would buy these two modules: one humidity sensorboard and one relay board for a combined cost of 2.44 euro!!! That already does more than your current set up. Dont get me wrong, it is a great, well detailed instructable, but it is kind of a waste of the Intel Edison, even if it was for free<br></p><p><a href="http://www.aliexpress.com/item/Hot-Selling-Soil-Hygrometer-Humidity-Detection-Module-Moisture-Water-Sensor-for-Arduino-NVIE/32275795794.html">http://www.aliexpress.com/item/Hot-Selling-Soil-Hy...</a> 1.24 euro<br><br><a href="http://www.aliexpress.com/item/5V-one-Channel-Relay-Module-for-arduino-free-shipping-N19/32317893729.html">http://www.aliexpress.com/item/5V-one-Channel-Rela...</a> 1.20 euro</p>
<p>thank you...</p>
<p>Very informative! Thanks sir.</p>
<p>thank you <a href="https://www.instructables.com/member/chrisjlionel" style="">chrisjlionel</a>...</p>
It's amazing sir. I love your writing style. Any one without tech background can easily follow this project. Keep up the good work.
thank you deba...
<p>too much power computing wasted...I mean is not too bad, but you could use something more compact.</p>
<p>can you be more specific...?</p>
<p>Nice project,But can't you replace the Edison with an cheap arduino,using Edison is wasteful,like killing mosquito with cannon. </p>
Thank you.. I have received Intel Edison kit from instructable for making projects. I will post an instructable soon using MediaTek LinkIt One board which is much cheaper than Edison.
<p>Thanks for reply,are Linkit One,Edison using the same code as arduino does?</p>
<p>yes, you can use the same code for both Edison and LinkIt One. Both are based on Arduino Uno</p>

About This Instructable




Bio: I like to make things more simple with easily available resources. My favorite quote: A human being should be able to change a diaper, plan ... More »
More by antoniraj:A Vegetable Cutting Tool From Trash Fresh Home-Made Pasta Using Plunge Cutters Stained Glass Indoor Hanging Flower Pot 
Add instructable to: