growing food with open source (sarah sharp)
DESCRIPTION
Open source folks are naturally lazy. Anything mundane task they can automate, they will. So what does an open source developer do when faced with planning, planting, and tediously watering a garden? Automate!Lazy hackers will appreciate the Garduino, an open hardware Arduino to automatically water your garden and tweet at you when your plants are thirsty. Want a frost alert on your android phone so you know to cover your precious tomato starts? How about a tool that tells you when to start seeds, when plants will be harvested, and whether you’re going to have too much lettuce in July? (Automatic seed planter not included.)Come discover open source tools for all types of garden hackers.TRANSCRIPT
Growing Foodwith Open Source
OSCON 2011Sarah Sharp@sarahsharp
Hello!
✔ Linux Kernel hacker
✔ Gardener
I'm still a lazy hacker
github.com/sarahsharp/GardenGeek
Problem #1: Scheduling
Garden Calendar tool
● 904 lines of C● Object oriented representation of plants● Takes a CSV file for input
● 11 magic fields● not all are required
oregon spring tomatoes,1,7,3,2010-04-13,0,75,.80,6,14,0
Garden Calendar tool: Phase I
● Started Feb 21, 2010● Plain text output on Mar 7, 2010
Issues with Phase I
● Worked pretty well● Seed germination
rates are optimistic!● Often forgotten● No integration with
other calendaring tools
Garden Calendar tool: Phase II
● Goal: output iCalendar and integrate with google calendar.
● Issues: RFC 2445
Issues with Phase II
● Google calendar update lag● Really should be a todo list
● Integration with Remember The Milk?● Need an easy way to defer tasks
● Web front end?● Storage for users
Problem #2: Frost
How Frost Works
How Gardeners deal with frost
Dealing with Spring Weather:“Cold Snaps”
Data Source: WunderGround.com,Portland, Oregon, USA,
April 2010
Lazy Hacker: Polling vs. Interrupts
Search for the Perfect Android App
● Need an alert for frosts● Alert must be timely● Nice: open source app
Weather Checker
● Need an alert for frosts● Alert must be timely● Nice: open source app
Weather Checker
Search for the Perfect Android App
● Need an alert for frosts● Alert must be timely● Nice: open source app
Weather Checker● Alerts too often● Alerts at the wrong time● “average” temperature?
● Need an alert for frosts● Alert must be timely● Nice: open source app
Weather Checker● Alerts too often● Alerts at the wrong time● “average” temperature?
DIY
“You may not use the Wunderground Data Feed for use in a mobile
application for mass distribution, even if there is no monetary cost for the mobile
application.”
Open Government Data
● NOAA weather data● No history, only future predictions● Only for the United States● SOAP interface that returns XML
Garden Weather Alert
Garden Weather Alert TODO
● Add a background task for alerts● Alert on hail, wind, extreme heat● Use GPS coordinates● Support international locations● Options for °F vs. °C
Automatic Wateringwith Arduinos
Garduino: Gardening + Arduino
● Automatically waters your plants based on soil moisture
● Good tutorial on instructables.com
http://www.instructables.com/id/Garduino-Gardening-Arduino/
Soil Moisture Sensor
http://www.cheapvegetablegardener.com/2009/11/how-to-make-cheap-soil-moisture-sensor-2.html
Soil Moisture Sensor Science
V=I*R
R = infinite ohms I = 0 ampsV = 0 volts
R is finite I > 0 amps V > 0 volts
Garduino Step 1:Build Soil Moisture Sensors
Garduino Step 2:Hello Blinky LEDs
Garduino Step 2:Hello Blinky LEDs
Garduino Step 2:Hello Blinky LEDs
Garduino Step 3:Hello digital output
Garduino Step 4:Set up watering system
Garduino Step 4:Set up watering system
http://powerswitchtail.com/
Garduino Step 5:Calibrate System
● Soil moisture sensor takes a while to react● Need Arduino code to:
● Limit how often the pump runs● Don't water more often than N seconds
● Issues:● No RTC on the Arduino● Use milliseconds from start
● ~80 lines of code (with detailed comments)
Final Garduino
powertail
switch
wallpower
Arduino
soilmoisturesensor
GarduinoDemo
What's next?
● Wireless communication● JeeNodes - $22 kit
● Finish irrigation system
Want get involved?
● http://www.gardengeek.org● http://github.org/sarahsharp/GardenGeek● Twitter/Identica: @gardengeekery
Thank you!