Autonomous Android Sprinkler / Pump controler
3/v1.0.5 is now up.
Some changes:
1. Fixed bug where certain characters in name fields were not handled correctly. We should be UTF-8 compatible now.
2. Fixed bug where editing on some enabled times was not allowed.
3. Added ability to quickschedule disabled schedules (they show up with the moniker « (disabled) », but they can be run)
2/I’ve got a new version that I’m going to upload tomorrow for beta testing. It has the following additional features:
- Support for Personal Weather Stations from Weather Underground
- Support for up to 15 zones.
- Ability to check on the data pulled from Weather Underground with a diagnostics screen
- Seasonal adjustment (0-100% of the set time)
- Home screen shows the configured time on the raspberrypi so as to avoid time zone confusions.
- Various bug fixes.
1/Here are the features:
Fully contained system with control logic and web serving.
Web based control (including mobile Android / iOS)
Automatic adjustment of intervals and duration based on weather conditions.
(weather underground API)
Weather conditions can be pulled from individual personal weather stations or from general weather data based on zipcode.
Manual Control
Named Scheduled Control
Quick Schedule
Named Zones Control
Full Graphing feature of historic logs
Ability to run with OpenSprinkler module / Arduino based module with direct relay outputs.
Supports master valve/pump output
Very simple installation
- One shot Gps based configuration for weather
Seasonal adjustment.
- Usefull for automatique swimming pool pump scheduling
Working on a few other things…
Here are a few screen shots from the software:
If something goes wrong on startup you can get some diagnostic information at /var/log/sprinklers_pi.
Once you’ve started things up, browse to port 8080 with a web browser. The system starts up in demo mode (i.e. it won’t actually switch outputs). To change the output type go to the Settings and change the Output type to « OpenSprinkler » (assuming you’re using the OpenSprinklerPi module).
For those who are particularly adventurous, the sprinkling logs are stored in sqlite3 database format, so if you really care, you can query them with SQL using the database at /usr/local/etc/sprinklers_pi/db.sql
FAQ
–
To make it work you need to get a free API key from Weather Underground at api.wunderground.com/weather/api/
Interval means how many days between waterings. So 1 would water every day, 2 would water every other day, 3 every 3rd day, etc.
« Normal watering » schedule will run tomorrow at 4:15 AM
or
Zone 1 « Front yard » is scheduled to run today at 10:00 PM
This is something that’s high on the to-do list.
I see in the code you posted on the wiki that weather adjustments start with 100% then add or subtract the 3 weather factors to come up with a percentage between 0 and 200. So if Weather Adjust is enabled for a schedule does it take precedence over the Seasonal Adjust from the Settings page, or are the two used together some how?
Just a thought, should the two adjustments be combined? For example, if Seasonal Adjust is set to 70% then the weather adjustment could take 70 and add or subtract the weather factors to come up with a final aggregate adjustment.
BTW, the github wiki says the humidity adjustment is 1/2% but the formula does 1%. I updated the wiki to say 1% (and expanded the explanation of each of the 3 factors). If you want 1/2%, which seems more appropriate, the code should divide by 4 instead of 2.
2 Events
00:03:21 2013/9/18 (4)
Event [00] Time:04:00(240) Command 3 data 0,0
Event [01] Time:05:00(300) Command 3 data 0,1
My schedule runs twice. What does the number in parenthesis mean? If it’s run time, is the weather adjustment applied to both times/runs?
If you watch closely, at 4AM you’ll see a bunch of additional events created. Command 1 means « turn on a valve » (data position 0 tells you which one). Command 2 means « turn off all valves ». The duration weather adjustment isn’t made until directly before the schedule is run (in case there has been some additional rainfall…).
I haven’t heard of anyone adding garage door support yet. The source code is available, hack away.
Somewhat related, how does sprinkler_pi handle weather adjustments when watering say every other day? Does it simply use the current day’s weather info? It would be nice if it could look back every day since the last watering and use the average of those days.
Currently it just looks at todays conditions and the rainfall from today and yesterday.
Zodiac69 wrote:Is it possible to include the current wind speed and « inhibit » the schedules if the wind speed is above value « X »?
I’m still trying to figure out what part of the country you are in. If the part with golf ball sized hail stones, I wonder how many personal weather stations survived yesterdays storm up in Gauteng?
Back to your topic, I’ve been thinking on the same lines as while most early mornings in Durbanville have almost no wind, we do have the odd day where the wind blows enough that I don’t want the sprinklers on, as the wind blows the water against the house, and due to the high Iron content, stains the walls.
I’ve got as far as mangling the code on my Pi to pull the metric values from WUnderground, and have added the current wind speed, but I can’t get the wind reading to display. Inhibiting the schedule is probably the best choice, as the wind only gets stronger during the day.
I’ve been looking at the way you adjust the schedule using WUnderground and have this question. How does the program adjust for today’s rainfall given that the API calls refer only to yesterday’s conditions?
Yes, it looks at today’s rainfall as well. If you look at the WUnderground Check screen (under the Advanced menu), you should see « Precip Today ».
At the moment I have a float switch in my tank to cut out the pump and restart when tank is full, also a pressure switch on the pump outlet, would this software be able to include these is some way?? I wish to add more zones and I have a pi so this could be a project that I would like to incorporate into my system
Munga, This seems like it would be pretty special purpose and wouldn’t be a feature that a lot of people would use. Keep in mind that you have the full source for the system, so you can do what you want with it. I would probably define a new class with your code in it, make use of the wiringpi libraries to get the state of inputs, and tie into the main control loop in the core.cpp file.
Awesome software! I just replaced the « dumb » box (a Hunter X-Core, 8-zone) with sprinklers_pi, and it feels liberating!A couple of questions:
1. How do you cancel a Quick Schedule? Rest System on the Advanced page?
2. How about showing how long a manual zone has been running on the main page? Right now it just says –:–
3. How about taking « tomorrow’s » weather into account as well? I’d hate for it to run a full soak on my lawn when there’s 80% of a Thunderstorm the next day. (I live in Houston Texas, itpours here!)
Again, thank you for your efforts!
1. An easy way would be to cycle the Run Schedules button on the main page.
2. That’s a good idea. On the TODO list.
3. So many people have such wonderful ideas for how to handle the weather. It seems that I should probably make the weather system more easily pluggable module so that people can do what they want. Also on the TODO list.