Then you just use the extracted value to define if that exact nozzle is activated and based on that do something. Following the soldering and assembly instructions, you could build your own web-based sprinkler controller from scratch, in a couple of hours. It included the PCB, all through-hole components, and a beautiful, clear-cover plastic enclosure. So a string.len function to find the length of your binary string then a string.sub to extract each individual value. OpenSprinkler 1.0 was released on as a DIY kit. I don't think it'll be terribly difficult, but reference is non-existent. I've done a bunch searches, but just can't find where to start as far as the coding this. Cross-platform: the same web app runs on iOS, Android, as well as Desktop browsers. Any example code of other virtual devices would help. You can do it by means of a simple loop and a short pieces of seek-and destroy code which takes the first digit out of the binary string, checks if the number is a one or a zero and then updates the zone status, then it removes that digit and starts over until there are no more digits in the binary string. Then just create an array with a value for each digit. But I'm not sure if fibaro will handle a binary value as a number by default, so you probably need to decode it for the box. So a 1 is an active zone and a 0 is an inactive zone? Because then it will be pretty easy to decode that string of ones and zeros into a functioning scene. Turn a zone on for 10 minutes: GET /sn1=1&t=600 The application allows you to automatically detect and control your OpenSprinkler irrigation system (s). Manual: GET /cv?pw=opendoor&en=1&rd=0&rbt=0&mm=1 Designed to allow intuitive control of the OpenSprinkler irrigation controller. You can OpenSprinkler Remote access through the use of Port-Forwarding. Below are some samples of calls to opensprinkler:Īuto: GET /cv?pw=opendoor&en=1&rd=0&rbt=0&mm=0 OpenSprinkler is an open-source, web-based sprinkler/irrigation controller. Download opensprinkler-card.js from the latest release and move this file to the config/www folder. I suspect running LUA code to execute or get zone states and loop will be more elegant, but beyond my knowledge.Īny help would be appreciated. Trying to add multiple lines to shutoff all other zones before turning one on does not run anything. Also, currently, you have to ensure all zones are off before manually turning another on or else water pressure is too low to pop up the sprinkler heads. I understand if nobody has used this, but just wonder how to handle a return value from an HTTP get to retrieve a state. What I'm looking for is how to retrieve a status into a variable to update the state of the icon. Looking at the LUA reference manual, I'm not really sure where to start and searches on this forum don't really yield any results that help. I'm having a heck of a time building on the basic functionality like getting feedback of the status to update the icon and more complicated actions in buttons. It allows me to toggle from auto to manual to off and turn each zone on and off. This app only works with the OpenSprinkler controller which must be installed and setup on your home network. I've created a simple virtual device to integrate opensprinkler into HC2. Welcome to the OpenSprinkler application.
0 Comments
Leave a Reply. |