close-circle
Close
0%
0%

AAGriculture (Automated Aquaponic Garden)

An ongoing attempt to subsidize my foodly needs and maybe provide a template for others to use for their own homes.

Similar projects worth following
I was getting tired of breaking the bank on buying produce that would inevitably rot in my fridge before I could ever get around to eating it. It was not only a waste of money, but also a waste of food that I felt pretty guilty about. If only there were a way where I could pick fresh vegetables from the plant as I need them and in the convenience of my own house...

Indoor aquaponics!

I live in a state where it's completely inhabitable outside for 5 months out of the year due to the cold, so traditional gardening wasn't that attractive to me. I also rent an apartment and have no other land, so a greenhouse was out of the question. I'm not going to be able to grow all of the food I eat, but I can certainly cut back on what I'm spending at the store and grow food year round. I think this is going to be a constant on-going project for me, ideally I would like to expand it to the point where I'm able to live off of it.

http://imgur.com/a/gVhve

Why aquaponics?

Compared to traditional farming, hydroponics has the potential to produce food while being much more efficient. Most hydroponics use a soil-less medium, eliminating the need for crop rotation, irrigation, or any of the other complications that come with soil. Hydroponic gardening also uses around 85%-90% less water than a normal garden, water that would normally be lost through runoff is instead recycled through the system.

There are a few obstacles to hydroponics, to be commercially profitable you need a lot of equipment and space. In the spirit of being a controlled system most operations are also indoors, safe from harsh weather or other pests. Also with no soil you have to supplement nutrients manually, at least from a hobbyist's perspective this can become quite costly. Aquaponics is taking all of the same principles from hydroponics, except adding fish into the equation to solve the fertilization problem.

The cycle starts with the fish producing ammonia, nitrification bacteria convert ammonia into nitrate, plants remove the nitrate from the water and it cycles back to the fish to start all over again. Cutting the costs and time spent from adding nutrients to your water is the largest benefit over hydroponics in my case. In a perfect aquaponic system the only input required would be food for the fish. Compared to fertilizer the food is cheap, and automatic fish feeders aren't anything new. In larger operations the fish themselves are another product, with separate tanks for spawning you could potentially maintain a healthy population of fish.

It makes sense to take an existing system found in nature and try to sustain it in a controllable environment, rather than trying to manipulate the system in an uncontrollable environment (irrigation, pesticides, artificial fertilization etc) which could have negative consequences. My project is an attempt to do exactly this, I may not make enough food to feed myself but it's a learning experience nonetheless. My ultimate goal is to learn the ins and outs of aquaponics and educate / offer services for anyone else who would be interested. As I go along I hope to come up with a well documented design that anyone could follow if they wanted to try it for themselves, or in other words, I'm making a lot of mistakes so you won't have to! I'm also hoping to use as much automation as possible along with a bunch of sensors and other fun things, I'll post information on these as well if I can get them running.

I've got an optimistic and cheesy vision for the future and can see this supplementing the future of produce, less big agriculture and more local DIY produce. The benefits are too great to ignore, no need for pesticides, no fertilization runoff, efficient use of water, and being able to produce in any climate year-round reduces the need for transporting food (saves money and lowers carbon footprint). It can be taken so much further too, apply solar energy for any electrical needs, spawn your own fish, keep bees for pollination, and maintain a mealworm colony for fish feed (feed them compost) and you've got a nearly perfect loop!

Thanks for checking it out!

BUILD DETAILS

MODULAR: The wooden frame is built and designed to be expanded if desired. By using bolts instead of screws I can disassemble it and easily add to the length of the frame. Initially I had purchased enough wood to make it 8' long rather than 4', but due to space issues I had to settle with 4'. Now that I've moved and have more room to work with I'm planning on cutting more material to increase the size.

AQUARIUM: The tank is 55 gallons and I picked it up for $25 at a local thrift store, which is an incredible deal considering I've seen new ones go for around $150! The currently stocked fish are 5 bluegill and 1 bullhead. I do not yet know if I've reached the most effective levels of ammonia for the nitrification process with the amount of fish I have, but I plan on monitoring this in the future. I've got a pump that...

Read more »

  • 1 × Atlas Scientific pH Kit
  • 1 × Raspberry Pi
  • 1 × 55 Gallon Aquarium
  • 1 × GrowStone Growing Medium
  • 1 × EcoPlus Submersible Pump ~800 gallons per minute

View all 15 components

  • Update: June 6th, 2017

    justin06/07/2017 at 03:57 0 comments

    So I keep coming back to this project because it's still a dream of mine to have a business (I'd settle for side hustle) of selling hydroponic produce, but not having a background in development among other distractions had been getting me down. Also I realize I don't need any of this fancy sensor jazz, but c'mon, gotta have it. Nonetheless, I've slowly been chipping away at it and with this update I'm happy to post that I've made some decent progress!

    I've probably scrapped my code 4 or 5 times along the way, there were many times where I struggled to grasp fundamental concepts of AVR programming and had to take some steps back to see how I was really trying to accomplish my goal of using this hardware. This while also juggling JavaScript / Node / MongoDB for the first time as a Windows sysadmin was kind of driving me mad, but it's paying off I think? I dunno, I ain't quitting my day job just yet, and I can't go intern as a junior dev cause I got bills to pay.

    Anyways I'm digressing quite a bit here, check out what I've got if you're interested.

    This project is really only two parts so far, the AVR sensor side and the NodeJS backend hooking up to Thingspeak.

    The board I'm developing on is the TeensyLC because it's crazy affordable for having 3 serial ports, each one dedicated to its own sensor (pH, ORP, and EC). And from the Teensy it's transmitting data from each sensor over Serial so that it can be read on /dev/ttyACM0 on my Node server using SerialPort. And from there it's pretty simple, it'll parse each line as they're received and assign the data to an appropriate variable which is then uploaded and graphed on Thingspeak.

    I'll post some more updates with photo, details on the program, and plans for the future. This was more of a 'oh shit it's actually working like 2 years later' update and I'm pretty excited!

  • 9/30/15 Update

    justin09/30/2015 at 18:19 0 comments

    So I had a major setback for this project, about a month ago I had to move! And let's just say it was a disaster as far as this project is concerned. I considered for about a week what it would take to pack everything up and get it moved into my new (much smaller) place, but to keep my sanity I ultimately decided against it and scrapped the whole thing. I threw out my wooden frame, still have my (empty) 55 gallon tank, gave the fish / tomatoes away, but that doesn't mean I'm giving up! I'm planning on recreating the whole project with more of a focus on aesthetics and practicality rather than volume, I think I'll continue to add updates on "AAG 2.0" here as much of what I'm trying to do still applies even though I'm downsizing.

    On the positive side of things I learned a lot about what I did wrong with this first attempt, namely my carpentry skills need some improving because it's not fun handling such a large volume of water when leaks are almost guaranteed and I'm at work for most of the day. I'm also going to take a different approach with sensors, I've got my eye on the GrovePi shield for the Raspberry Pi and I'll be looking into that as a solution. And now that space is such a scarce resource I'll be trying out some ideas for utilizing vertical space for growing, I'm hoping things in my life will calm down soon and I can get a proof-of-concept out within the next month.

    While I haven't been working on this project for a little while I have been looking in to what it would take to sell produce to restaurants and at farmer's markets. In setting my own expectations I'll probably be doing only the latter since I won't have nearly enough produce to do anything besides sell a couple dozen heads of lettuce, but if I even get that far I'll be extremely happy.

    So here's to a fresh start, I'm honestly taken aback by how much attention this project has gotten here and am very grateful and inspired to get back to building!

  • Update

    justin06/21/2015 at 04:56 0 comments

    I thought I might post a bit of an update here, I've made some slow progress and with some motivation I hope to be able to have something to show here pretty soon. I've created a Github page here: https://github.com/jvshens/AAG in trying to get 3 sensors working on Teensy-LC I've taken the test code from AtlasScientific's page and sort of cobbled it together here with the SerialCommand library written by Steven Cogswell http://awtfy.com/

    It's been a lot of fun reading up on all of this, I've never attempted anything like this before so it's tough but very rewarding. The code I have posted on Github doesn't actually work yet, it's sort of just a cobbled together mess of the probe's demo code and my interpretation of how SerialCommand works. Ideally I want to be able to send commands to the Teensy over the usb Serial connection which will then perform the defined functions, e.g. PH ON or PH OFF. There will be 3 sensors and only 1 monitor so I'll need a way to switch between them, and that's what this is for.

  • We have a reading!

    justin05/25/2015 at 23:22 0 comments


    It took less than 24 hours for Atlas Scientific to respond to my question about why I couldn't get the thing running, it turns out I have an older model that requires a 38400 baud rate (opposed to 9600 in some documentation) which is awesome because that's an easy fix (and props to them for replying so quickly). After applying that and uploading it to the Teensy-LC I was able to get a constant stream of readings out of the buffer solutions. Assuming that the buffer solutions are correctly advertised I'm a little concerned that the readings may be off. For example, while calibrating I had the probe in the 7 pH buffer and it was reading 7.25 rather than 7. It could be that the buffer is a bit old, they have expiration dates for 2016 and I've had the kit for nearly a year. The company does say that there are quite a few variables involved that can affect a reading, I can see this as being an issue for anyone needing scientifically accurate readings but in my situation a ballpark reading will probably be fine.

    I used Teensyduino on my Windows machine to configure the Teensy-LC with a basic program provided by Atlas Scientific, once it was set to output continuously I plugged it into my Raspberry Pi and was able to read the pH levels with cat /dev/ttyACM0. I suppose now if I enable SSH I could remote in to the RPi from anywhere, provided I can access my home's LAN, and check what the pH levels are. While that's sort of cool I don't think it's all that useful, but it does sort of pave the way for additional sensors.

    My next step will be to see if I can figure out how to take the output from /dev/ttyACM0 and use it in a script or program. I'm presuming I'll need to assign the output / device to a string which can then be called on. I also haven't figured out how to send arguments to it either, some forums suggested trying to echo a character to the device like this: echo "E" > /dev/ttyACM0

    That should have stopped the continuous readings but nothing happened, if I want to change what the sensor is doing I have to connect it back to my desktop and send the arguments through the Arduino IDE serial monitor. Will update again if I make any more progress, thanks for sticking around!

  • Still no pH probe

    justin05/25/2015 at 00:04 0 comments

    My Teensy-LC came in the mail (thanks guys!) and I immediately soldered some pins onto it for breadboard testing. After some light reading I got everything up and running inside the Arduino IDE and was ready to test my Atlas pH probe, unfortunately there wasn't much testing to be done since I immediately ran into the same problem I had with the Raspberry Pi. Despite having the correct wiring as per Atlas Scientific's documentation I'm unable to get any sort of response from the probe over UART, I even threw it onto a Mega 2560 just to recreate their documents exactly and got the same results. I'll be contacting their technical support and hopefully I can get this resolved, in the meantime I'll be doing some research on other sensors and getting more savvy with writing programs.

  • Teensy-LC, could it be?

    justin05/13/2015 at 22:32 0 comments

    Maybe! We'll see.
    At least for me... Okay enough of that.

    To be blunt, I don't have a lot of hardware experience but I've always had an interest. I'm using aquaponics as my "excuse" to learn how to use computer hardware in order to automate some of the processes and output readings so I know what's going on. In short, I've got 2 or 3 variables in my garden that I would like to have accurate readings for using a couple of different sensors. Being able to read things like pH, nitrate levels, dissolved oxygen, C02, and flow rate are the first things I need to figure out before any additional automation can happen.

    I don't have the expertise to do anything in the way of customized PCB, so I've been looking into Raspberry Pi and Ardunio boards for i/o over serial connections. I've had some success but I think that the Teensy-LC would be perfect for this while keeping the overhead of costs and power down. Having three serial connections in such a small package is awesome. I was considering buying a more expensive Arduino 2560, but after learning about this it could be exactly what I need at half of the cost. If possible I would like to set this up with multiple sensors, have it output to an RPi and push that information on to the internet where I can keep track of everything on my phone while I'm away. If I get to the point where this is all up and running the next step would be controlling it remotely, features like changing the water pump timing, light control, flow rate control, feeding times and levels, C02 release, and an emergency shutoff.

    So you know, big dreams and lots of work ahead!

    Bonus Garden update:

    When I was having issues with leaks I wasn't running the pump as much, seriously stunting the growth of my new tomatoes. However since my last update 2.5 weeks ago they've almost doubled in height, my tallest plant (closest to the window) measured in at around 12-14 inches last time and now it's up to 23! I'll be trellising them up on the ceiling which should look pretty cool in about a month, I honestly may be in over my head here (puns win hackaday contests, right?). I don't have sensors at the moment so I have no idea what the nitrate or ammonia levels are like, but apparently it's working.

  • UPDATE: April 26th, 2015

    justin04/26/2015 at 19:28 0 comments

    I've been pretty busy lately with other projects and work, but I'm not going to let this one fall into the aether!

    If I had known how awful vinyl hoses and plastic couplings are to work with when I started experimenting with aquaponics I would have steered clear from the beginning. The most recent change I made to my system was replacing my leaky drain hoses with much more reliable bulkheads and water potable pipes.

    Here's what it looked like before, it's a mess of vinyl, silicone, bondo (was getting desperate), and when it all failed I had plastic liner to catch the leaks. I wasn't using proper bulkheads with rubber seals and instead relied on holes drilled through the bottom with silicone to prevent water from leaking around the edge of the hose. As it turns out, silicone doesn't like to bond with smooth HDPE liner, because of this I had tons of leaks to deal with on a regular basis.

    Here's the new stuff, getting to the hardware store is pretty inconvenient for me and of course you can't make just one trip and expect everything to fit. Or at least in my case, I guess measure twice cut once hasn't resonated with me yet. But since I didn't want to go back I did some improvising with a hacksaw and gorilla glue, so far it's working well!

    I have to say, investing in a GOOD set of hole saw bits would have saved me from a lot of frustration. I actually broke the guide bit and bent one saw from trying to do a quick job. But at least I got it done, it still doesn't scream 'designer asthetics' but compared to what it used to be it's muuuch better in form and function.

    And just an update on what I'm actually growing, the kale is growing at a steady pace and my tomatoes have shot up surprisingly quickly. I'd like to start logging growth tracking correlations with environmental factors (C02, ammonia levels, more daylight with spring etc) once I can get some sensors working. As for right now I may just start keeping track of size.

    Tomatoes after about 1.5 months:

    I threw an aloe plant in just to see what would happen, I'm really a novice gardener and don't know anything about most plants. But that's what makes it fun, right? I thought that it might be similar to a cactus where too much water could kill it, but from what I can tell it's thriving and quite plump.

    And finally, I'm getting closer with my Raspberry Pi PH sensor kit from Atlas Scientific. I've got it all wired up and ran some Python scripts, unfortunately with all of the documentation out there I can't seem to get it to read properly. I've got it in UART mode and I can control the LED (off and on) but beyond that no dice. I'm following this guide here so I'm not sure how accurate it is, I may just need to contact Atlas and have them help with the troubleshooting: http://www.instructables.com/id/Atlas-Scientific-and-Raspberry-Pi/?ALLSTEPS

    I'm still only about 75% satisfied with my system, if I had the time I'd build another one from scratch with everything I've learned. With the automation I'd like to get pH readings, dissolved O2/C02, and flow rate. There's also some hydroponics company out there who developed application software specifically for reading this kind of stuff, I'm blanking on the name but will update as soon as I remember. I bought a ton of LDPE liner to replace the HDPE, it's much easier to work with and will still get the job done. I'll be rebuilding the trays pretty soon here to ensure that there won't be any leaks, seeing as I'm on the second floor of an apartment (that I don't own) I get pretty anxious about the thought of dropping gallons of water on the floor while I'm not home.

  • TO-DO List

    justin03/11/2015 at 20:27 0 comments

    March 11th, 2015

    • Raspberry PI configured with Atlas Scientific PH monitor
    • Automated fish feeder
    • Nitrate / ammonia monitor
    • Automatic RSS/live Twitter updates from PI board
    • Change the tray draining method, far too often there are leaks due to the silicone coming loose

View all 8 project logs

Enjoy this project?

Share

Discussions

warshof wrote 05/24/2016 at 02:52 point

Check out HYDROPONIC.io . It's Currently up for sale and fits you nicely.

http://flippa.com/6430722

  Are you sure? yes | no

Adam Vadala-Roth wrote 05/03/2015 at 22:07 point

Interesting project, I am doing something similar myeself! How are you finding the Atlas Scientific stuff? I'm on the fence about buying their kit or just going a head and reimplementing all of it as open hardware..........

  Are you sure? yes | no

justin wrote 05/04/2015 at 05:22 point

Good to hear!

Admittedly I'm having some trouble with it, I can run some test scripts that seem to detect it but any command I send via the RPi don't seem to work. I'm pretty sure I have it wired properly but my Python skills are pretty weak. I'm gonna try running it on an Arduino instead, there seems to be better documentation for it and it'll be less complicated.

If it's a total flop I was thinking about trying the Vernier pH probe and Arduino sensor shield. From a novice's perspective they seem to have more information on getting things up and running, which for me would have been great to start with.

I'd be curious to see what you end up doing!

  Are you sure? yes | no

Adam Vadala-Roth wrote 05/04/2015 at 18:52 point

I found a blog where someone worked out all the math for pH measuring and processing as well as the circuit, I'm gonna start with rolling my own implementation of that, then go from there. Ideally I just want dissolved oxygen, pH, and temp of water.

  Are you sure? yes | no

justin wrote 05/13/2015 at 21:27 point

I just took a look at your project page and I'm really impressed with the scope, I would love for something like the sensor hub you've prototyped to be readily available. I'm not very experienced with hardware but kind of threw myself at this project as motivation to learn, I'll definitely be following your work closely and would even like to collab if possible.

In addition to those sensors you might want a nitrate probe, I only say might though because it may not be as useful in your hydroponic setup. The ammonia in my system isn't as controllable as measured fertilizer so that's something I'll be looking into.

  Are you sure? yes | no

Adam Vadala-Roth wrote 05/16/2015 at 20:20 point

Hey man thanks for your kind words!  If you wanna collab, I've been throwing the idea around for a beta hardware pool. Meaning I'd get together interested parties who want to try out the system or the hardware (as in just hack it no necessarily use it the way I intend) and we all pitch in for the hardware cost and end up with a set of baords at a lower price. Going through OSHPark gets me 3 of each thing, doing a couple orders + bulk components could bring the cost down a lot per person. That's what I'm thinking about right now for collaboration since the hardare is nearly fully realized the software is where things need to evolve and the best way to do that I think is to get hardware out there and have the hackers code it. PM me if you are interested.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates