September 2, 2015 at 6:51 am #40097
Hi, what about a rain or soil moisture sensor with WiFi.
Add a small solar/battery supply and you have a cheap standalone wireless sensor.
And the ESP8266 ESP-03 have a analoge input chanel. So we dont need any arduino IC between the Sensor and Wifi modul.
Its possible to send the data direct to the OpenSprinkler API. For powersave, maybe every 10/30/60 minutes or event triggert (rain start/stop).
other application would also be possible, like: dry-run sensor, wireless Flow sensor input, mini weather station (temp, humidity, rain, soil moisture), wireless On/Off switch (for my grandmother how understand no smartphones, Apps and so), wifi extention board,September 2, 2015 at 7:40 am #40099
for the solar, battery system we can use the MAX1551 IC. This is a battery charger IC with two inputs. Solarpanel and USB to load a 3.7V LiPo.September 2, 2015 at 7:41 am #40100
I’ve purchased the parts I need to build a soil moisture sensor module that uses an XBee instead of WiFi. My gardens aren’t all within range of my router. See this thread for more details and this link for where I got my inspiration. My plan is to assemble the parts and take a crack at incorporating it into the unified firmware code this winter. Just as you suggest, I’d have the XBee wake up at some configurable? interval, take a reading, transmit to the base station, and go back to sleep.September 2, 2015 at 8:19 am #40102
@Mike this is a nice project and you have build the basics for a wireless sensor. Good job! I think, the easiest and flexible way for all simular projects is to interact with the OS over the API. You just need to send from anywhere a command like this: “http://IPorURL:port/jw?pw=PASSWORDinMD5” + your data “ms=moisterSensor”
for you project, you need a python script thats reads the xbee and send a string with the value to a adress. And all other project have a easy interface to.
i post this idea here: https://opensprinkler.com/forums/topic/feature-request-api-interface-for-external-sensors/ (i know – the false forum)
this would be a great solution for easy DIY weatherstation and sensor integration. what do you think about it?September 2, 2015 at 8:33 am #40103
haha, i paint something… what could be possible:
Attachments:September 2, 2015 at 10:10 am #40106
David I like your idea of interacting with it over the API. I’ll have to start by reading the API documentation.September 2, 2015 at 1:46 pm #40107
@Mike thanks, but until now there is no API input for own weather-stations. we have to ask ray or prog this feature by our own and make a pull request to merge it to the main code in github.September 8, 2015 at 11:54 pm #40166
Since OpenSprinkler uses WUnderground.com to obtain weather data, only weather stations that are registered with WUnderground may be used.
However, since the firmware makes weather query through a script, it is possible to set up your own script that makes use of your local weather sensor data. Alternatively, if you have a server that queries your sensors and calculates a watering level, you can have the server call the existing OpenSprinkler API (i.e. setting the ‘wl’ variable) to feed the result to the firmware. This way, you can integrate data from your own sensors and not be restricted by what the default script provides.September 9, 2015 at 4:17 am #40170
i overlooked this API function.
@Mike, you can set your own waterlevel, calculated by your weatherstation. Just send the API command: http://yourIPorAdress:Port/co?pw=PassMD5hash&o23=100
To set the waterlevel to 100% Now, you dont need to change the firmware. Only a small script with a json request.September 9, 2015 at 11:46 am #40172
That’s a great idea! I could write my own script that accesses my soil moisture sensor and calculates a % watering level. I use an OSBo so I could then host the script on it. I can create a program that uses a weather adjustment and set the weather adjustment method to manual. My script will provide the % watering level.
1. I believe the OS firmware polls WU at some interval. How can I poll my custom script instead of WU?
2. If I have multiple soil moisture sensors, how can I differentiate between them? For example, I might have a program and a soil moisture sensor for the potted plants on my deck and also have a program and sensor for my vegetable garden in the ground. The pots will require more frequent watering than my vegetable garden.September 10, 2015 at 5:06 am #40177
A solution for you second question could be this: You have a small weather server for your sensors. If one sensor says – hey, this plants need water. You can send a API command to start a run-once program. “Station 2 (petted plants) run 30 min” = http://yourIPorAdress:Port/cm?pw=PassMD5hash&sid=1&en=1&t=1800
Look at the API docu “under manual station run” for details.September 13, 2015 at 11:06 pm #40208
@Mike: the upcoming firmware 2.1.6 allows you to change the weather script location. Actually if you are going to change the firmware code it doesn’t really matter because you can directly change the default weather script location, which is specified in ‘defines.h’.
If you have multiple soil sensors you have to give each one a unique ID.September 18, 2015 at 10:19 pm #40275
Ray I’ve been pondering this for the past few days and reading the API documentation and I think I’m still missing something. I don’t understand how to set a %WL that is different for each program or station. I’d like to create programs using OpenSprinkler, set them to use weather adjustment and then either feed or request a different %WL for each one individually. The %WL would be calculated by my own script. Is that possible?September 20, 2015 at 1:27 pm #40292
@Mike: the ‘wl’ variable is a global variable that gets applied to all. However, each program has a ‘Use Weather’ flag which allows you to select whether ‘wl’ will be applied to that program or not. If ‘Use Weather’ flag is off, that program is not affected by ‘wl’. Otherwise the station run times are all multiplied by ‘wl’. So it’s essentially a binary choice. Now, do you need each program to potentially use a different ‘wl’?
I should mention that it’s certainly also possible to use a script to change the station water time within each program (i.e. modify the program directly). This way you get the maximum flexibility.December 13, 2015 at 2:27 am #40979
How i can build my own firmware and and is it possible to use it with some modifications into the required conditions?
What are the full specifications of the all parts?
And what about its power supply and the battery consumption?December 16, 2015 at 12:40 am #40998
- You must be logged in to reply to this topic.