The most exciting thing for someone new to monitoring, control and automation over the internet, is being able to manually turn something on or off using your computer, tablet or phone, from anywhere.
Inevitably, the next step is to automate the control. Some automation examples include toggling the relay based on environmental conditions, sensor reports, time, GPS coordinates, motion detection or some combination of these.
We break down the uses of the Arduino in aquaponics to three main categories
Monitoring. Using sensors to monitor the environment be it air or water temperature, relative humidity, light levels, etc.
Control. Manually prompting an action, turning a pump on/off, grow light on/off, opening/closing windows, etc.
Automation. Combines steps one and two to use sensor readings to implement controls, without your input.
What kind of automation projects can the Arduino solve for aquaponics? Actually, there are many, but here are a few.
Backup pump triggered when primary pump died (true story).
Automatically increase/decrease pump cycles on consecutively cloudy/sunny days
Grow lights based on time of day, cloudy/sunny conditions
Light shades on bright days
Open/close greenhouse windows based on climate forecast
Toggle Portable heaters or air conditioners
Toggle light on when you enter greenhouse/basement/garage
No matter what intelligence you want to implement, it all starts with getting the relay talking to the internet and that is what this project is all about. The webapp is bare bones except for an On/Off button.
The demos of our projects are found here:http://adacsprojects.appspot.comHow it works
The technique we are going to use is polling and is analogous to a child sitting in the backseat on a long road trip asking "Are we there yet?" every twenty seconds. An Arduino will make a GET request to App Engine, which will query the datastore for the relay entity and return the relay's state property. The Arduino will parse the response and trigger the relay pin HIGH/LOW.
The webapp is a simple image, whose class changes based on the the current state. Click the power button image and it will toggle the class, create an AJAX request to the server which in turn will toggle the state property of the relay entity in the datastore.Parts List
1 x Arduino Uno R3
1 x Arduino Ethernet Shield, R3
1 x Powerswitch Tail II
2 x breadboard male/male jumper wires
1 x Arduino wall wart (optional, for better power)Software Versions
Arduino IDE 1.0.3
Google App Engine, Python SDK 1.7.4
The web application runs on Google App Engine. Our previous Instructable, https://www.instructables.com/id/Aquaponics-Online-Temperature-and-Humidity/
, discusses how to create an application.
This project is a part of the Arduino Data Acquisition and Control System described in more detail in our upcoming eBook, Automating Aquaponics with Arduino