loading

A garden controller helps us to manage the environment by controlling fans, heaters, lights, pumps, and notifying us when the garden needs our attention.

The Garden Controller System will help you to grow:

  • Greens such as lettuce, spinach, Swiss chard, and kale.
  • Herbs such as basil, parsley, oregano, cilantro and mint
  • Tomatoes, peppers, strawberries, and many more

using hydroponics (or soil) because I believe everyone, even on a budget, should be able to grow their own plants at home without having to go through the painful process of learning what does and doesn't work. I've distilled it down to an electronic control system that provides you with the insight you need to get your little green friends growing and thriving. I want to help you learn more about your plants by using the controller and using helpful reminders..

I recommend using hydroponics, before you try aquaponics - try hydroponics so that you know what success looks like! Also, for growing indoors it's a must, besides, plants will grow much faster after germination.

Just about any plant can be grown hydroponically, but for beginners it is best to start small. The best choices are herbs and vegetables that grow quickly, require little maintenance, and do not have a huge variety of nutrient needs. You want fast-growing plants so that you can assess how well your system works and tweak it as necessary. It would be a real letdown to wait months until harvest time only to find out your system is not working properly. Low-maintenance plants are great for beginners because they allow you to focus on learning about your system. If you are growing a variety of plants it is also important to make sure that they are similar in their nutrient requirements, so that they grow well together.

Step 1: Requirements

After trying several different styles and configurations of hydroponic gardening, I decided a robust control system needed the following traits:

  • A modular controller system that doesn't break the bank. Low-cost, but effective and easy to troubleshoot. What every product is supposed to be, but rarely is!
  • Alert me when my plants need my attention. It is helpful to have reminders to check-in on my garden and alerts if appliances such as fans, lights, pumps, heaters need adjusting. Can’t spend all my time watching you guys grow!
  • Regulated temperature and humidity in my growing environment. In my closed indoor space, the exhaust and intake fans, humidifier, and dehumidifier should all be toggled as needed based on self-monitoring sensors.
  • Regulated delivery of nutrient solution. Ideally, my nutrient solution pump should operate for at least 5 minutes every half hour. By automating the pump cycle, plants receive optimum nutrient levels.
  • Light sensors. For indoor growing, I personally prefer the lights be on traditional mechanical timers but I wanted my controller to be able to know when the lights are on. And tell me if they go off before they should.
  • What’s going on in there?! You know what would be awesome? An LCD with cool buttons to show the status and communicate any messages that I need to know. It would be even more amazing if I could receive text messages (SMS).
  • Remote message commands (in development). If needed, I can send a remote command to override the controller via text. This function is currently undergoing testing, as are email alerts. Doesn’t need the Internet to function. For security and practical reasons, the controller should not need to have access to the Internet unless I decide.
  • Data logging. Check the history of my system with an optional method for logging data that can later be analyzed.
  • Keep the clutter minimal. You want the minimal amount of equipment inside the growing environment, too many wiring, wires, cables, etc., can be a real pain. I decided to use a wireless remote control set with on/off buttons on the remote so that I could program the Arduino-based system to take control and verify my commands are followed.
  • Green wizard needs food, badly. The controller should know the level of nutrient solution in the tank and notify me when it is low.
  • Available to everyone. Being open-source and community-oriented is very important to me. I firmly believe that anyone who chooses to spend a little time and effort can learn to build and upgrade their own modular garden system.

Step 2: Gather Your Arduino and Friends

Parts:

  • Arduino Uno R3 ( this project can be extended using more units.)
  • Arduino Uno Protoshield
  • Real-Time Clock module (DS3231)
  • 10k resistor
  • male pcb headers
  • female pcb headers
  • wire w/ connectors for the sensors
  • DHT21/22 Temperature / Humidity sensor
  • Photocell
  • Water Level Sensor
  • Dallas Temperature Sensor (for nutrient solution temperature)
  • 433MHz RF Transmitter & Receiver Modules
  • set set 5 pack of Wireless Controlled Outlets (recommend Etekcity 5 Pack Auto-programmable Function Wireless Remote Control Outlet Switches)
  • 2 or more - nRF24L01 2.4Ghz Wireless Radio Transceiver modules

Optional Parts:

  • Arduino Uno R3* or Pro Mini*
  • Real-Time Clock Module
  • Optional: nRF24L01 Adapter with 3.3v regulator
  • connector wires
  • Display Option LCD w/ buttons Shield + Arduino Uno R3*
  • 2 x 4-pin male header connector wires
  • SD Card Option SD Card Shield + Arduino Uno R3*
  • connector wires
  • Internet Connectivity Option Ethernet or WiFi Shield + Arduino Uno R3*
  • connector wires - see https://www.instructables.com/id/Custom-Wire-Connectors/
  • PVC conduit box w/ lid

Tools:

Step 3: Soldering Review

If you are not comfortable using a soldering iron, please consider brushing-up on it before proceeding with the next step.

http://www.aaroncake.net/electronics/solder.htm

Step 4: Solder Some Bits to the Prototyping Shield and Sensors

  • Solder the headers to the protoshield into position (indicated in the picture)
  • Solder the 10k resistor to the pins for the DHT sensor. (shown in the picture)
  • Solder the 4-pin connector to the Real-Time Clock module (as shown in the picture in the next step.)
  • Solder two wires with connector to the Dallas Temperature sensor.
  • Solder three wires with connector to the DHT sensor.
  • Solder any remaining optional sensors.

I've included some datasheets to help with pinouts but if you are using the same protoshield you should be able to follow the pictures.

Step 5: Assemble the Controller

Seat the protoshield into the female headers on the Arduino Uno*. Connect the sensors and RTC (Real-Time Clock) module to the protoshield as pictured.

Plug-in the USB cord and connect it to your computer with the Arduino Compiler software available at arduino.cc. I personally prefer working with the Atmel Visual Studio environment because it does an amazing job with code completion and library linking. (contact me if you'd like help switching using Atmel VS)

Step 6: Download the Source-code and Modify

Download the source-code from GitHub.

In the source-code I created a base foundation for managing, transmitting, and receiving "sensor" objects and "appliance" objects. This project could easily be modified to work with other environments in which control is achieved by reading sensors and operating appliances based on programmed rules. You'll need to make a few adjustments to the source-code in order for it to work properly with your wireless outlets. To make the changes, you'll need to find out what the codes are that your wireless remote control uses and the outlets are programmed to receive. I have included a sketch for installing onto your Arduino Uno* w/ protoshield to set the Real-Time Clock to the current time and step you through the process of acquiring the codes. You will need to insert the 433Mhz Receiver module (as pictured) and upload this sketch StartCore.ino to the Arduino Uno* and open up the serial console for that port so that you can receive data from the Arduino. After you complete the process of acquiring all of the codes from your remote you can copy and paste directly into TheDecider.h header file where I have indicated.

Step 7: Compile and Upload

Make the modifications to the source-code as shown in the included readme file. The controller has been programmed to help you maintain optimum growing conditions so plants with thrive. You are welcome to make changes, adjustments, tweaks, whatever you like to customize the controller to your style of gardening.

Compile the source, upload to Arduino, and the controller is ready to use provided a power source. The USB or the barrel jack are typically used to power the device.

Step 8: Assemble the Receiver

Let's assemble the parts we'll be using to build The Receiver.

  • Connect the nRF24L01 and RTC (Real-Time Clock) module (as pictured).
  • The nRF24L01 connects to the protoshield so that the Arduino can communicate wirelessly with The Receiver. (The Receiver is a second Arduino Uno* or Arduino Pro Mini*.)

The Receiver will use the built-in I2C communications capability to connect to a Display (LCD) shield, SD Card data logging shield, Internet connectivity shield, if you dare ;-p and even SMS text messaging.

Step 9: Repeat the Steps

Each microcontroller we use needs to be programmed.


Plug-in the USB cord and compile the source, upload to Arduino, and the controller is ready to use provided a power source. The USB or the barrel jack are typically used to power the device.

Are you ready to dig deeper into the inner workings of this project?

https://www.instructables.com/id/DIY-Hacking-your-o...

Step 10: FAQ

Why doesn't the controller connect directly to the Internet?

I have also evaluated many other similar projects and found that the more complex garden controllers typically connect you to the Internet of Things. Personally, I do not want to share my garden’s data and potentially its control to just ANYONE (e.g. remote servers) unless I choose to do so. I strongly believe that the Internet of Things is a potentially dangerous path and will most certainly be exploited by those who wish to hurt honest people for their gain. The more control we give to the Internet of Things, the more we enable dependence on the internet and give away the simple freedom to live our lives in a way that we choose. I may sound a bit paranoid, and maybe I am, but hopefully I have at least convinced you to think more about what or WHO has control over your appliances. Having said that, this project is capable of connecting to the Internet. ;-)

Does this project include measuring pH and/or E.C.?

The option to use these sensors has been considered, however, not been implemented as of now. The pH of water is an important measurement whether you are gardening indoors or outdoors, soil or soil-less, because it affects whether a plant can properly take in nutrients. The electrical conductivity (EC) of water estimates the total amount of solids dissolved in water -TDS, (Total Dissolved Solids). TDS is often measured in ppm (parts per million). In hydroponics, this measurement is used to determine the approximate concentration of nutrient solution to water.

I decided that the cost of including these sensors far outweighs the benefit of constant monitoring. I recommend a hand-held pH tester such as the Oakton EcoTestr pH 2 Waterproof pH Tester, which is excellent for the home gardener and has been proven time and again to be accurate. There are many hand-held EC devices available as well and if you are checking the pH, it’s a great time to check the E.C. If there is enough interest in adding these sensors to the controller, it’s flexible and open-source and I’m willing to work with anyone interested.

What do I need in addition to the CoreConduit Garden Controller?

The basic equipment needed to successfully garden indoors using the controller: http://www.hydromazing.com

<p>I made some systems and i'm using this code on an arduino uno. website: http://hydromazing.coreconduit.com</p>
<p>Thank you very much for you article, I'm a software programmer trying to grow my first hydroponics garden so this has been very helpful. </p><p>Just out of curiosity, what do recommend for handling a big garden? Say if I need to put these sensors at various locations in the garden, have them all send data to a central server (rasberry pi or just a normal computer), then have the central computer issuing commands to either an Adruino board or Rasberry Pi to trigger certain action such as watering the garden or turning on the fans?</p>
<p>Thank you for taking the time to let me know your feedback!</p><p>I designed the garden controller system using wireless modules so that you can scale the garden. Each remote unit can communicate with the remote monitoring module and controller module. I have evolved this project to what I am now calling hydroMazing. The project is currently using 2 x Arduino Nano and 1 x Arduino Uno with LCD buttons shield.</p><p>The next step is the Raspberry Pi...</p><p>So if you, or anyone else who is reading this, would like to contribute to this project it is open for you to do so. I am currently working to update the source-code at GitHub.</p><p><a href="http://hydromazing.coreconduit.com/" rel="nofollow">http://hydromazing.coreconduit.com</a></p>
<p>This is really cool! I've been growing plants at home for a long time, but I've never automated the process before. So many great ideas here and so many ways to customize it! Thanks for sharing! </p>
<p>Black Jalapenos and Jimmy Nardello's Peppers growing under the control of the CoreConduit: Automated Garden Controller System. :-)</p>
Impressive! You got my vote.
<p>Merhabalar, yapmış olduğunuz topraksız tarım otomasyonu &ccedil;ok ilgi &ccedil;ekici. Kullandığınız sens&ouml;rleri nereden temin edebilirim, şimdiden teşekk&uuml;rler.</p><p>http://www.kizoyunlarii.net bende arduino ile yapmış olduğum projelerimi bu sitede paylaşıyorum, bir g&ouml;z atmak isterseniz sevinirim.</p>
<p>Great post. I was checking continuously this blog and I&rsquo;m impressed!<br>Extremely helpful information specifically the remaining phase :) </p><p>I take care of such information much. I used to be seeking this particular information for a very long time. </p><p>Thank you and best of luck.</p>
<p>nice work!</p>
So if you don't connect the system to the internet, how does it notify you?
<p>Thank you for this question.</p><p>- piezo buzzer ( waka sound indicating the alert number)</p><p>- LCD with buttons shield shows the alert and reason.</p><p>- working on adding support for the ESP8266, mainly to access the Internet to send SMS messages to phones.</p>
<p>i have never attempted to do any arduino projects ever once and im wondering if this would be ok for me to do at my experience level. i have been inspired by your instructable so much that its the first one i wanna try cuz its so bad ass. and if its a lil too complicated for me could you point me in the right direction please. this is the type of stuff id love to go to college for.</p>
<p>Thank you for your comment! Sorry for the delayed response. Instructables doesn't seem to send me emails anymore. I would consider this project to be intermediate to advanced. Having said that, my goal is to use it as a real-world tool for learning electronics and programming microcontrollers. I'm constantly updating documentation and source-code. The more questions you and people like yourself ask the more I can try to make this useful. Thanks much!! Cory</p>
<p>any advise is great</p>
<p>When growing hydroponically, I have found best results using either DWC (Deep Water Culture) or Drip Ring, which is the same except that there is a ring on top dripping water over the growing medium. DWC uses an air pump (like for fish aquariums) to keep fresh air pumped into the water. Use a 3 parts nutrient solutions such as GH Flora Series and a helping of compost tea. Do not fiddle with the pH. If you are using clean tap water with an E.C. &lt; 100 and pH out of the tap at around 7-8 you will most likely not need to do any adjusting after you add the nutrients. Next, is ventilation, the plants need fresh air including the seedlings. A wet environment and stale air are a good combination for problems. I hope some of this helps. The results are amazing!!</p>
<p>Your software for download doesnt mention SetupCore.ino, but maybe that is 'StartCore.ino'<br>&quot;Controller_nRF.ino&quot; is I take it the main program<br>By the way, I found the way you setup your program with e.g. the &quot;TheDecider.h&quot; file an interesting way of doing it. Thought me something</p>
<p>Thank you for taking the time to comment and provide some terrific information. I'm familiar with some of the options you described for a moisture sensor and I'm personally moving away from using them. The gypsum version makes sense, though, I'd like to try a clay-coated moisture probe. I'm leaning more in the direction of monitoring the flow of the nutrient solution so that I can catch clogs, failures, possibly even leaks. As you've mentioned, the moisture probes are not the best long-term solution. Thank you for catching the StartCore vs. SetupCore, I've changed the documentation to reflect the SetupCore in the software. Again, very informative comment and I sincerely appreciate you sharing :-)</p>
<p>I am always interested in any garden automatisation project :-)<br>Though the light sensor and waterlevel sensor board are quite cheap, your arduino can do the same function ofcourse with its analog ports and just an ldr and 2 spikes.<br>Can I ask what lights you are using?<br>I have done a similar project, currently just in a carton box clad with alufoil, a single cheap LED lamp and a 12 Volt car heater and that does quite well actually... but as it is a small box I mainly use it for seedlings to grow early so I extend my planting season. I am not sure how the plants would be with the LED when they get bigger.<br><br>Choice for the DS3231 is a good one. It is hardly more expensive than the 1307 and much more accurate. The data logging option is a nice feature :-) but I found that in practice it doesn't really add benefit unless one is someone who likes to store data.</p><p>With soil moisture sensors the problem is always corrosion. Can I ask how long your probe lasts? (that is if you know already). I only have experience with nails, that lasted about a season. But due to corrosion build up, the readings drift during a season.<br>I have countered that by feeding the moisture sensor (in my case just two nails) under control of the arduino and only take a reading once every hour. In between there is no current flowing through the sensor so there is no (electrolytic) corrosion.<br>I have been experimenting with AC (or at least a pulsating if not alternating current), seeing the soil more as a dielectrium than as a resistance and that works well too.<br>The advantage of seeing the soil moisture as a capacitor rather than a resistor is that the readings are more a reflection of the water content than of the nutrient content.<br>As you already refer to, the resistance of soil greatly depends on the soluble salts coz pure water actually doesnt conduct electricity very well. Therefore the readings of your soil moisture sensor would change if you for instance add nutrients. It may indicate it is &quot;wet enough&quot; while in reality it is measuring soluable nutrients.<br>But if you know your soil, obviously a resistance measurement is still very usable.<br></p><p>Expanding a bit more on the corrosion: I have experimented with feeding the sensor from two digital pins in which one functioned as ground and the other as V+. In combination with taking long breaks between readings, it also allows to let your electrodes go through a recycling in which you reverse the current and damage of electrolysis should be reversed.<br>Ofcourse this will 'cost' you two extra digital pins and it really doesnt add much to the lifespan.<br><br>I have also tried gypsum sensors, some people find them the holy grail, but i found them cumbersome :-)</p><p><br>I like your idea of using RF to switch stuff (a pump I presume). I thought of that too late :-) but it is ok as my fan and heater are 12 Volt and my light is on a seperate timer</p>
out of curiosity could you wire one of those hand held sensors into your system and just have it checked periodically? also, how do you feel about aquaponics? and do you know of any sustainable way to get nutrients for your plants? like any ideas how to make it closed loop or at least create the nutrient supply from a waste stream?
<p>The hand held sensors used for checking E.C. and pH are too expensive to &quot;tinker&quot; with in this way. If you must measure these readings constantly then I recommend spending the money for legit sensors: <a href="https://www.sparkfun.com/products/10972" rel="nofollow">https://www.sparkfun.com/products/10972</a></p><p>Aquaponics is great! However, I personally do not wish to care for fish. I am interested in more natural nutrient solutions and I'll be sharing my favorite hydroponics compost tea soon. As for nutrients from a <a rel="nofollow">waste stream</a>.</p>
Nice. One possible change might be to use a raspberry pi in place of the uno, you won't need a data logging shield, and it can more easily interface if you wanted to do email alerts or such, or setup a local webpage (not Internet)
<p>Thank you for the feedback and suggestion! I considered the raspberry pi for those exact reasons. I still think it would be a great option for the receiver and not too difficult to incorporate. I'm looking into it and receptive to any help from others. The controller's use of analog inputs combined with the low-cost of the Arduino Uno and ProMini with the nRF24L01 is a great way to setup your controller and sensor network.</p>
Awesome upload thank you for sharing! I would love to see you implement an EC meter but more importantly a ph meter because ph is known to fluctuate out of ranges especially using different regiments of fertilizers from start to finish. An and txt alert would be SWEET!! also I would love to see the online links to where you bought your list of supplies. There's so many sources it's hard to know which ones sell &quot;noncloned :D&quot; parts <br>Thank you again awesome instrucatble
<p>Thank you so much for your feedback! We can connect an EC and/or pH meter to a Pro Mini with the nRF wireless module. Make a few additions to the controller's source code and we'll have it. The data would be interesting, but I caution against trying to control either the EC or pH using this method because they fluctuate naturally. We would want to consider this when updating &quot;TheDecider&quot; function because changes should only be made when a specified tolerance has been reached. I check my EC and pH periodically, every other day to every few days, if there is an issue, I take care of it at that time.</p><p>Open-source hardware - <em>Imitation is the highest form of flattery ;-) </em> There are so many &quot;cloned&quot; parts on the market that your best bet would be to buy from a well-known reputable dealer such as Jameco, Adafruit, or Sparkfun. Many, many great deals are available on eBay but you can't be certain that what you'll receive will work, let alone be genuine. I personally buy from vendors whose products I can trust. </p>

About This Instructable

28,409views

355favorites

License:

Bio: I have a degree in Electronics Engineering and various certifications in all kinds of internet programming languages. Professionally, I have over 20 years of experience ... More »
More by bitsandbots:How to Start Growing Indoors Smart Garden System Private Web Serving with the Raspberry Pi 
Add instructable to: