The Vera Community forums have moved!

Advanced => Programming => Plugins & Plugin Development => Topic started by: brucehvn on January 11, 2015, 06:12:57 pm

Title: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on January 11, 2015, 06:12:57 pm
**** Update 03/01/2015 ****
OpenSprinkler just released their unified firmware 2.1.3 which means that the API should now be stabilized between the regular OS, the OSPi, and the OSBBB.  They also added hashed md5 passwords to the API.

The files that are attached here are now only compatible with firmware 2.1.3 and above.  They should work now no matter what version of the OS you have as long as you can run firmware 2.1.3.

*************************

Based on the discussion here (http://forum.micasaverde.com/index.php/topic,15738.0.html), I'm posting some updated files for the OpenSprinkler plugin to allow it to work with the latest firmware (mine is running 2.1.2).  This is a rough beta, but appears to be doing what it should.  The instructions I'm going to give below are for UI5 because that's what I use.  I can't really answer any questions on UI7 installation.

The first step is to install the current OpenSprinkler plugin from the app store if you haven't already.  The files I'm putting here are just updates to the existing files so there's no formal install for them yet.

Next you should backup the files that we are about to overwrite.  Go to Apps->Develop Apps->Luup Files and download the following three files:
I_OpenSprinkler1.xml
D_OpenSprinkler1.json
D_OpenSprinkler1_UI7.json

Save them somewhere so you can restore them later if necessary.

Because the new firmware for OS returns everything in JSON, I opted to use akbooer's JSON parser library.  You will need to install this to /usr/lib/lua (usually done via scp or sftp).  If you use any of akbooer's other programs/plugins, you may have it installed already.  You can get the file from here (http://forum.micasaverde.com/index.php/topic,29989.0.html).  That's the official thread for the parser and the latest version will be available there.

Once those steps are done, you are ready to upload my updated versions of the three files you backed up above (you did back them up, right?)

Using the same Apps->Develop Apps->Luup Files screen, browse for my copy of the three files attached here so they show up in the right hand side of that screen, ready for upload.  Check the "Restart Luup after upload" check box and hit the "Go" button.  Vera will restart the luup engine.

In order to see the UI changes, you might need to refresh the vera page in your browser, or maybe even clear your browser cache and reload.  When it's working right, the main OpenSprinkler controller device will only have "Disable" and "Enable" buttons next to each other instead of "Off", "Manual", and "Auto" in one column.

Debugging is turned on, so there will probably be lots of feedback in the logs which could be helpful to me if you see any issues.

Configuration is pretty much the same as for the old plugin.  You can look at the original thread (http://forum.micasaverde.com/index.php/topic,15738.0.html) for more info.  I've added one new variable called ManualMaxMinutes which by default is set to 1.  If you want to control the valves manually with vera, then set this to some number that is probably more realistic.  The valves will run no longer than this amount when you turn them on manually.  I had to do this because the new API requires a time be passed in when turning on a valve manually.  You can always still turn them off early, however.

I have been using 20 seconds for the status update time as opposed to the default 2 seconds.  That seems plenty for me and cuts down on some network traffic and vera overhead.

So, give it a whirl and see how it goes.  Let me know of any issues or other features you might like to see.

Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: xuniman on January 19, 2015, 10:39:04 pm
So I had some free time and thought I would give this a try. So far no luck. Here's what I've done:

I checked to make sure that dkjson.lua was in /usr/lib/lua (I had EventWatcher loaded)
I backed up the files you directed. I uploaded your new files and set the lua engine to restart
I cleared the cache in Chrome

When I look at the OpenSprinkler device I now see enable and disable instead of the auto/manual/off
 I don't see your new variable in the advanced tab of the device??

Nothing seems to actually do anything but there are no errors generated

Any troubleshooting tips? I'm happy to be a beta tester. I have a Vera 3 running UI5 and another test Vera 3 running UI7 (both seem to be the same)
My OpenSprinkler is a OSPi unit that is now running the 2.2.2 software (I tried a git and that's what loaded). It says it's from 1-13-15 so really new. It may have broken what you tried to do.

Let me know if I can help.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on January 20, 2015, 01:34:15 am
So I had some free time and thought I would give this a try. So far no luck. Here's what I've done:

I checked to make sure that dkjson.lua was in /usr/lib/lua (I had EventWatcher loaded)
I backed up the files you directed. I uploaded your new files and set the lua engine to restart
I cleared the cache in Chrome

When I look at the OpenSprinkler device I now see enable and disable instead of the auto/manual/off
 I don't see your new variable in the advanced tab of the device??

Nothing seems to actually do anything but there are no errors generated

Any troubleshooting tips? I'm happy to be a beta tester. I have a Vera 3 running UI5 and another test Vera 3 running UI7 (both seem to be the same)
My OpenSprinkler is a OSPi unit that is now running the 2.2.2 software (I tried a git and that's what loaded). It says it's from 1-13-15 so really new. It may have broken what you tried to do.

Let me know if I can help.

Thanks for the info.  So, for the firmware, you used their firmware upgrade tool and the version it gave you was 2.2.2?  Did it say that was a beta or anything?

Did you set your zones in the ZoneIds variable, and if so, do you see the child devices being created for those?

Are you able to ssh to your vera unit?  If so, you could pull some info from the logs and it might tell us more about what's happening.  Let me know if you can ssh in and I'll tell you what I need you to do.  I can also try and install the 2.2.2 update and see if I encounter any issues.  I'm guessing they might have made some change between the 2.1 -> 2.2.  But if I do that, it will probably be a few days before I can get to it.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on January 20, 2015, 02:40:26 pm
I just downloaded the firmware update tool from OpenSprinkler.  My hardware appears to be the latest, 2.2 and the latest firmware it offered me was 2.1.2 which is what I already have.  I'm using the standard AVR based version though.

It looks like the OSPi uses a completely different way of updating software and I wouldn't be surprised if the versions don't match.  The key is whether the API is consistent across versions of OS.  I will write Ray and ask about this.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on January 20, 2015, 08:28:05 pm
I talked to Samer at OS support via e-mail.  It appears there are some differences in the API between the OSPi and the Arduino based units.  The firmware for the OSPi is user contributed and developer updated, so while they strive to have API compatibility, there are some things that are different.  He offered to send me the list of things and how to tell which unit is being used.  So if I get that list, I will try to update the plugin to accommodate the various models.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: benr on January 27, 2015, 01:10:22 pm
Nice. Ill keep an eye on this thread I just found out about OpenSprinkler and for $99 with all this functionality its sounding like a good deal. Plus I noticed in the latest HomeWave update support for the OpenSprinkler Plugin was added which is a major plus.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: tomtcom on February 22, 2015, 07:26:41 pm
I originally looked at the Asante irrigation controller. However it only has 6 zones and I need 8 so OpenSprinkler is what I'd like to get. My birthday is less than a month so.......lol...

I hope you are still working on this. I would certainly help out with testing as I did with a MyQ device for my garage. I just like how OpenSprinkler is literally meant to be open and not all the other closed proprietary solutions. Thanks!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on February 22, 2015, 08:17:25 pm
I originally looked at the Asante irrigation controller. However it only has 6 zones and I need 8 so OpenSprinkler is what I'd like to get. My birthday is less than a month so.......lol...

I hope you are still working on this. I would certainly help out with testing as I did with a MyQ device for my garage. I just like how OpenSprinkler is literally meant to be open and not all the other closed proprietary solutions. Thanks!

I haven't really heard any complaints about the arduino based open sprinkler running with this version of the plugin.  I have to make some changes to get it to work with the Pi version of the unit.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: tomtcom on February 22, 2015, 09:20:35 pm
I didn't readily see the difference on their site nor a reference in the faq. How are you knowing what you get directly from their site?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: tomtcom on February 22, 2015, 09:23:31 pm
I didn't readily see the difference on their site nor a reference in the faq. How are you knowing what you get directly from their site?
Edit....I meant pi or arduino.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on February 23, 2015, 06:18:41 am
I didn't readily see the difference on their site nor a reference in the faq. How are you knowing what you get directly from their site?

As far as the end user is concerned, you probably wouldn't see much difference between the arduino or pi versions.  But from the aspect of someone developing the software, or in this case a plugin for the unit, there are some differences in the two.  Obviously, the arduino and pi are using two completely separate micro controllers, which means the firmware is not identical.  The firmware is developed by different developers and while they try to maintain compatibility with the API, the pi version is lagging behind somewhat, so we have to code around those differences.

On the website, this page (https://opensprinkler.com/products) lists all the various options.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: tomtcom on February 23, 2015, 08:56:13 am
Ahh, I see. Thanks for that. Sorry I missed it.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: kyle.dawson on February 27, 2015, 09:56:01 pm
I have OSPi.   I love how it has raspberryPI.  Did not realize that OpenSprinkler and OSPi had different API.  I would developer for mios app gets this working for OSPi.OSPi was so easy to setup and replace my existing system, 10 min. Can control via phone while at home.  Once it works with Vera, I would have one interface to all my stuff and access to OSPi via internet via vera apps.


Here is my version of OSPi
Software version: 2.2.30 (2015-02-21)

Kyle
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on February 28, 2015, 04:10:27 am
I have OSPi.   I love how it has raspberryPI.  Did not realize that OpenSprinkler and OSPi had different API.  I would developer for mios app gets this working for OSPi.OSPi was so easy to setup and replace my existing system, 10 min. Can control via phone while at home.  Once it works with Vera, I would have one interface to all my stuff and access to OSPi via internet via vera apps.


Here is my version of OSPi
Software version: 2.2.30 (2015-02-21)

Kyle

The API is mostly the same, maybe about 85%.  The Pi version is just lagging behind the development of the Arduino based version a little bit.  Since your firmware version was just released about a week ago, they might have made some more advances and I'll need to check out to see what they've done.  The biggest hurdle is that the Pi version still used the Auto/Manual mode settings in order to control valves individually (which is what we need from Vera), but the Arduino version has done away with that concept entirely.  I've been a little swamped and haven't been able to get finished incorporating the Pi support into the new plugin.  But hopefully I'll have something for you Pi users to try out soon.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: kyle.dawson on February 28, 2015, 09:21:17 am
Thanks for follow up.  If you need help, testing, coding, let me know. I can help.  Not sure if you have pi version to test with.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: Ramias on March 01, 2015, 07:31:33 am
New unified firmware just posted.

This means the same plugin should work for all platforms.

https://opensprinkler.com/forums/topic/announcing-opensprinkler-unified-firmware-2-1-3-for-avrrpibbblinux/

But the password string is handled differently.

It now requires and md5 hash of the password instead of the clear text.  Not sure how this will work with the Vera plugin since it is winter here and my sprinklers are still disabled.

you can use the fciv.exe tool (Search and download from microsoft) to generate an md5 hash easily on Windows.  Or maybe the plugin can be changed to take the password in clear text and send it in md5?

New features are sunrise/sunset control on the sprinkler controller.

Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: brucehvn on March 01, 2015, 04:33:39 pm
New unified firmware just posted.

This means the same plugin should work for all platforms.

https://opensprinkler.com/forums/topic/announcing-opensprinkler-unified-firmware-2-1-3-for-avrrpibbblinux/

But the password string is handled differently.

It now requires and md5 hash of the password instead of the clear text.  Not sure how this will work with the Vera plugin since it is winter here and my sprinklers are still disabled.

you can use the fciv.exe tool (Search and download from microsoft) to generate an md5 hash easily on Windows.  Or maybe the plugin can be changed to take the password in clear text and send it in md5?

New features are sunrise/sunset control on the sprinkler controller.

Wow, this is great news.  I'll have to download it and put it on my OS so I can test with it.  This should make my job much easier  :)

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.x
Post by: johnes on March 01, 2015, 08:04:36 pm
The new plugin seems to be working great... although it is winter and won't be able to actually test for a while, it seems to work.   It only detected zones 1 and 2, but after I updated the list, it pulled in all the info from the others.

Thanks!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 01, 2015, 09:48:17 pm
I've updated the first post with a new I_OpenSprinkler1.xml file.  This should now work with the new unified firmware 2.1.3 and above and hopefully will work with no tweaks on the OSPi.  Because they now use a MD5 hash on the passwords, this new file will only work with firmware 2.1.3 and later.  If you aren't ready to update your firmware, then don't upload this new version of I_OpenSprinkler1.xml.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kyle.dawson on March 01, 2015, 10:23:44 pm
Just tried plugin with new file, getting new error:


OpenSprinkler : Error manually controlling valve Bad Status Code: 404



OSPi
Software version: 2.2.30 (2015-02-21)


FYI.. In Florida, so I can do any testing you like.. 75 here today  :)

Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 01, 2015, 10:40:43 pm
Just tried plugin with new file, getting new error:


OpenSprinkler : Error manually controlling valve Bad Status Code: 404



OSPi
Software version: 2.2.30 (2015-02-21)


FYI.. In Florida, so I can do any testing you like.. 75 here today  :)

Hi Kyle,

I'm not sure what the software version 2.2.30 refers to, but in order for this to work, you would need firmware 2.1.3 which is the new unified firmware for all versions of OS.  In the "About" portion of the software, it should say something about what firmware version you are running.  Check out the post here (https://opensprinkler.com/forums/topic/announcing-opensprinkler-unified-firmware-2-1-3-for-avrrpibbblinux/) which was just posted today.  The 2.1.3 firmware is considered beta for the OSPi.  It may be completely different than what you are running on there now.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kyle.dawson on March 02, 2015, 09:30:43 am
I think there may be other UI on the PI versions.   Here is the one I have:

http://rayshobby.net/mediawiki/index.php/Python_Interval_Program_for_OSPi


Attached is my UI.  Maybe I have the wrong UI?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 02, 2015, 01:21:05 pm
I think there may be other UI on the PI versions.   Here is the one I have:

http://rayshobby.net/mediawiki/index.php/Python_Interval_Program_for_OSPi


Attached is my UI.  Maybe I have the wrong UI?

Yes, I think the new unified firmware is different than the python version you are using.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kyle.dawson on March 02, 2015, 11:32:23 pm
I was able to get the beta version installed.  Vera Plugin works with the new firmware.  It saw my sprinklers and was able to start them from Vera.   My issue, the program on the PI keeps crashing.  But this is beta, so I will wait until they work it out. But great news, the vera plugin does work on the OSPI version.   One note, I had to disable security for my test.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: rstrouse on March 02, 2015, 11:35:08 pm
Is there any advantage to buying the PI or BeagleBone version vs. the prebuilt one?  I just placed my order for the prebuilt one and a 16 station expander.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 02, 2015, 11:39:15 pm
Is there any advantage to buying the PI or BeagleBone version vs. the prebuilt one?  I just placed my order for the prebuilt one and a 16 station expander.

I think the Pi and the BB version are for people who are into those boards, have experience programming them or maybe have extras laying around.  The standard arduino based version is fine for anyone who's not doing their own microcontroller stuff.

I do a lot of arduino programming, but I think their stuff is pretty good, so I don't really see a need to muck around with my own version of the firmware.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 02, 2015, 11:40:21 pm
I was able to get the beta version installed.  Vera Plugin works with the new firmware.  It saw my sprinklers and was able to start them from Vera.   My issue, the program on the PI keeps crashing.  But this is beta, so I will wait until they work it out. But great news, the vera plugin does work on the OSPI version.   One note, I had to disable security for my test.

That's great news.  Not the crashing, of course, but the fact that the plugin seems to work with no modifications :)
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: rstrouse on March 03, 2015, 12:53:57 am
So as a guy with a drawer full of pic programmers, I'm not missing anything?  I suppose if I want to fart around with a beagle or pi I probably don't want to mess with my irrigation anyway.  I got a lot to lose if that's not stable.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kyle.dawson on March 12, 2015, 01:22:43 pm
Just wanted to follow up, I have mine working with OSPI beta.  Looks like they did some updates last week or so, not mine works and does not crash.  I can control with this plugin via scenes. I use scenes so I can control via my phone and the AutHomation andoriod app.  Great work on this plugin, very simple to install and use.


Kyle
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomtcom on March 12, 2015, 03:15:41 pm
So how do you use it Kyle? Do you have like 5 scenes correlating to each irrigation zone as an on/off with the predefined run time?

As you use it in authomation I mean.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 12, 2015, 03:47:45 pm
So how do you use it Kyle? Do you have like 5 scenes correlating to each irrigation zone as an on/off with the predefined run time?

As you use it in authomation I mean.

Yea I haven't found much use of this. I have had to add my own options like runing a full cycle not just open and close one valve. Also when I run a zone I would like my predetermined time to run, each zone is different. Right now I can set only run time for all.
So to me this plugin needs alot more features to make it something more then just manual turn on/off.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kyle.dawson on March 12, 2015, 05:01:39 pm
I admit, the OpenSprinkler is really all I needed, it has app and really runs on its own with logging, etc.  I just wanted to have one feature, ability to control from internet without putting the OpenSprinkler on the internet directly for on demand on/off.   I am coming home from work and decided I wanted to mow, I can tell it not to run so when I get home, grass is not wet. My entire design for my automation is that Vera is my Portal for my home.  I have lots of apps and systems I can open to the internet, but the fewer the more secure I may be.  I really like the option to connect all my systems together, so if one day I need it, its there. 


As for what I did, I have three zones.  I create 6 Scenes, on/off for each zone.  Create Favorite area named sprinkler, I can see all 6 on one screen.  I let the OpenSprinkler run is programs, the zimmerman logic with the weather lookup feature.  That really has the best water solution for me.  I set to run 30 min, but based on rain, humidity, temp, etc... It will change the run time from 0% to 200% based on past and future weather.


I plan to have the datamining vera plugin as well, that would help me calculate how much water I use based on run time I hope.  OpenSprinkler has this data, but not as rich as I could do in Vera. 


Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 12, 2015, 06:11:58 pm
I am coming home from work and decided I wanted to mow, I can tell it not to run so when I get home, grass is not wet.

Is this using the enable/disable on the master? I guess that's a pretty good use.

Other then that I found that I can train my Mailman to not walk across the grass and use the walkway instead. Thanks to camera/motion setup I used to use only for notification now can flip on the sprinklers for 10 sec.   
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: automationKing on March 24, 2015, 11:58:08 pm
Is there any way to turn the debug logging off?  95% of my log is opensprinkler...

Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 25, 2015, 01:12:20 am
Is there any way to turn the debug logging off?  95% of my log is opensprinkler...

I see the same
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 25, 2015, 03:55:49 pm
Is there any way to turn the debug logging off?  95% of my log is opensprinkler...

Sure, at the top of I_OpenSprinkler1.xml you will see something like this:

Code: [Select]
  local TASK_HANDLE = nil
  local PW = ""
  local HASHEDPW = nil
  local MSG_CLASS = "OpenSprinkler"
  local DEBUG_MODE = true

Just change the DEBUG_MODE variable to "false" and it turns off the debug logging.  Upload the file after changing it and restart luup and it will be set.

Since most people seem to be working fine with the current code, I'll probably make that change myself and post it here soon.  There might be quite a bit of non-debug logging as well.  If you still feel it's a bit too verbose for you, then let me know and I'll see if I can move some of that into debug output.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 25, 2015, 05:31:12 pm
Is there any way to turn the debug logging off?  95% of my log is opensprinkler...

Sure, at the top of I_OpenSprinkler1.xml you will see something like this:

Code: [Select]
  local TASK_HANDLE = nil
  local PW = ""
  local HASHEDPW = nil
  local MSG_CLASS = "OpenSprinkler"
  local DEBUG_MODE = true

Just change the DEBUG_MODE variable to "false" and it turns off the debug logging.  Upload the file after changing it and restart luup and it will be set.

Since most people seem to be working fine with the current code, I'll probably make that change myself and post it here soon.  There might be quite a bit of non-debug logging as well.  If you still feel it's a bit too verbose for you, then let me know and I'll see if I can move some of that into debug output.

Bruce

I decided to just remove the plugin for now. I was having issues with the edge slowing up and after posting the logs people recommend house cleaning.

The Open Sprinkler API is very good and has a complete list of options that can be sent via Http. The plugin Didn't have time settings, run all zones or alot of other useful options that I could see. At this point it seemed better to setup a few Scenes with wget Http commands to.

What are the planned expansions on this plugin? 
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 25, 2015, 06:38:06 pm
I decided to just remove the plugin for now. I was having issues with the edge slowing up and after posting the logs people recommend house cleaning.

The Open Sprinkler API is very good and has a complete list of options that can be sent via Http. The plugin Didn't have time settings, run all zones or alot of other useful options that I could see. At this point it seemed better to setup a few Scenes with wget Http commands to.

What are the planned expansions on this plugin?

It kind of depends on what people want out of this plugin.  The OS software is really pretty good, and there's no real good way to duplicate a lot of the functionality in the vera UI.  So, I think the main point of the plugin was to make sure there was manual control of your sprinkler valves and any scheduling, etc., that one might want to do could be done through vera scenes.  The plugin uses the HTTP API, that you are using in your scenes, but there's likely to be people that aren't that familiar with using wget and HTTP calls, so using the scenes to operate valves via the plugin makes more sense for them.

So, if there are suggestions that make sense to have in the plugin, then I'm certainly open to looking into them.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 25, 2015, 06:59:13 pm
I decided to just remove the plugin for now. I was having issues with the edge slowing up and after posting the logs people recommend house cleaning.

The Open Sprinkler API is very good and has a complete list of options that can be sent via Http. The plugin Didn't have time settings, run all zones or alot of other useful options that I could see. At this point it seemed better to setup a few Scenes with wget Http commands to.

What are the planned expansions on this plugin?

It kind of depends on what people want out of this plugin.  The OS software is really pretty good, and there's no real good way to duplicate a lot of the functionality in the vera UI.  So, I think the main point of the plugin was to make sure there was manual control of your sprinkler valves and any scheduling, etc., that one might want to do could be done through vera scenes.  The plugin uses the HTTP API, that you are using in your scenes, but there's likely to be people that aren't that familiar with using wget and HTTP calls, so using the scenes to operate valves via the plugin makes more sense for them.

So, if there are suggestions that make sense to have in the plugin, then I'm certainly open to looking into them.

Bruce

Sounds logical, I'll work on a few ideas I have now and see how that goes.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 25, 2015, 07:15:15 pm
Sounds logical, I'll work on a few ideas I have now and see how that goes.

It certainly would be feasible to grab the programs people have programmed into OS and their names and create child UI elements for those like we do for the manual valves.  Then you could basically start a program from a vera scene.  But it still remains to be seen if that's really necessary when you can schedule those programs so easily in OS.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 25, 2015, 07:38:07 pm
Sounds logical, I'll work on a few ideas I have now and see how that goes.

It certainly would be feasible to grab the programs people have programmed into OS and their names and create child UI elements for those like we do for the manual valves.  Then you could basically start a program from a vera scene.  But it still remains to be seen if that's really necessary when you can schedule those programs so easily in OS.

Bruce

Yea I see where your coming from. Maybe this is more then enough in Vera for most and use the OS app for the rest. I'm playing with Virtual Panel also and this might be a good place to setup a tile with all of this and multistring to get some current data in there too. Like count down timer and such.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: automationKing on March 27, 2015, 01:40:09 am
A few thoughts:

 - Yeah, I edited the XML, so that worked great.  Thanks...
 - As far as scheduling?  I use OS's builtin feature to turn sprinklers on/off.  Would be cool though, to be able to disable/enable sprinklers from the plugin.  Think remotely/on vacation.  Plus I love that it gives me the ability to turn the stations on/ff if I wanted to.  Say just for fun, or because I detect motion, etc.

The author is right, there's no reason to duplicate any functionality in OS, but what e has there now seems to be a good match.  Perhaps the only thing I 'd do is move the debugging log leves up to the UI level.  In any case, I love having this plugin, and appreciate the effort involved.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on March 28, 2015, 03:29:07 am
Would be cool though, to be able to disable/enable sprinklers from the plugin. 

I think what your asking for is on the master plugin already no?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on March 28, 2015, 02:32:58 pm
Summer is coming, and it's time to update my plugin and firmware.... 

One question i had... are/were you guys using the virtual rain sensor along with this plugin?  Worked great... but seems like potential overkill now that it's built into OS.  (and i could use the same weather underground key). 

Ironically, that's also the key reason i wanted Vera integration in the first place.  So (as you are discussing already on this thread), do i really need this plugin that much, other than additional control from one main interface for all my HA stuff?

What am i missing?

Also, i see that my version for the plugin (with auto update) is v1.4.  what version is the latest? 
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: TC1 on March 28, 2015, 05:00:10 pm
I don't use this product (yet), but one practical application of having Vera talk to any irrigation system is for scene/mode integration.

As others have stated, let the sprinkler do what it does best (schedules, zone control, moisture sensing, etc) but allow your HA system to override the scheduling. Perfect example: you have a party or just know know that people are coming over, you activate your "party" mode or scene on Vera (disables auto-locking on the doors, puts some music on, maybe lighting, etc) and that in turn also temporarily suspends any zones scheduled on the sprinkler.

Another use case is approaching or leaving the house, your geo-location or alarm arm scenes/modes could also temporarily suspend watering.

If people are already using the present plugin in this fashion, awesome. I look forward to adding an irrigation system to my home this spring.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 28, 2015, 08:50:27 pm
Ironically, that's also the key reason i wanted Vera integration in the first place.  So (as you are discussing already on this thread), do i really need this plugin that much, other than additional control from one main interface for all my HA stuff?

What am i missing?

Also, i see that my version for the plugin (with auto update) is v1.4.  what version is the latest?

The plugin basically gives you some manual control over the valves from vera and also lets vera know when valves are turned on.  So, if that information is useful for scenes, etc. it's available.

As far as the version, if you are getting it from the marketplace, then you have the version that runs with the older OS firmware.  This update I did is for the latest firmware on which they've changed so many things, the plugin you have would not work anymore.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 28, 2015, 08:52:59 pm
As others have stated, let the sprinkler do what it does best (schedules, zone control, moisture sensing, etc) but allow your HA system to override the scheduling. Perfect example: you have a party or just know know that people are coming over, you activate your "party" mode or scene on Vera (disables auto-locking on the doors, puts some music on, maybe lighting, etc) and that in turn also temporarily suspends any zones scheduled on the sprinkler.

Another use case is approaching or leaving the house, your geo-location or alarm arm scenes/modes could also temporarily suspend watering.

If people are already using the present plugin in this fashion, awesome. I look forward to adding an irrigation system to my home this spring.

Certainly doable.  The current version of the plugin has the ability to enable/disable OS, which is probably what you would want to do in the scenes you describe.  Temporarily disable the unit for the conditions you mention, then re-enable them later.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on March 28, 2015, 08:56:31 pm
Ironically, that's also the key reason i wanted Vera integration in the first place.  So (as you are discussing already on this thread), do i really need this plugin that much, other than additional control from one main interface for all my HA stuff?

What am i missing?

Also, i see that my version for the plugin (with auto update) is v1.4.  what version is the latest?

The plugin basically gives you some manual control over the valves from vera and also lets vera know when valves are turned on.  So, if that information is useful for scenes, etc. it's available.

As far as the version, if you are getting it from the marketplace, then you have the version that runs with the older OS firmware.  This update I did is for the latest firmware on which they've changed so many things, the plugin you have would not work anymore.

Bruce

Thanks Bruce.

Based on their new firmware, is there any reason to run the virtual rain sensor any longer?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: brucehvn on March 28, 2015, 09:00:12 pm
Thanks Bruce.

Based on their new firmware, is there any reason to run the virtual rain sensor any longer?

Probably not.  Since OS can now query the weather and adjust watering levels based on the conditions, I personally don't see much need for it.

Bruce
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on March 28, 2015, 10:02:10 pm
Thanks Bruce.

Based on their new firmware, is there any reason to run the virtual rain sensor any longer?

Probably not.  Since OS can now query the weather and adjust watering levels based on the conditions, I personally don't see much need for it.

Bruce

Kinda what i figured... but it's a great add-on plugin!!!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on April 11, 2015, 02:38:29 pm
Upgraded today... seems to be working great.  As i'm on U15 still, i didn't upload the v17 jason file. (right?)

one thing that is off. on the main OS device, i have the enable and disable buttons, and they are controlling the OS perfectly.  But they are not reflected the actual "state" of the device after selection.  They remain grey, no matter which choice i currently have selected. 

any ideas?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: bwillette on April 25, 2015, 02:29:45 pm
As i'm on U15 still, i didn't upload the v17 jason file. (right?)

I performed the upgrade today on UI5, and went ahead and uploaded all three files, and things seemed to work fine for me, with the buttons showing the expected states.

Thanks for putting together this plug-in update!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: TinCup on May 04, 2015, 10:00:49 pm
Good work, Bruce!  Got my OS integrated fairly simply with Vera UI5 using this plugin and the latest OS firmware.  Spent some time messing around with PLEG to try and manage watering schedules but in the end, I just decided it was easier to let OS do it.

I re-used a Hunter Rain Clik sensor I had with my irrigation system and modified a few lines of Bruce's xml code to pull its status out of OS and into a Vera variable (compliments of a previous poster's code mod).

I have a scene that runs some lua code at 4am to comparatively check the physical rain sensor and the trip status of the Virtual Sensor plugin.  They both have to match indicating no rain before Vera enables the irrigation system.  Probably overkill but it works for my application.

Thanks again to Bruce for updating this plugin ...
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: MLabuda on May 08, 2015, 01:40:59 pm
Just an FYI in case anyone else runs into this issue.

OpenSprinkler firmware v2.1.4 came out a few days ago.  I performed the update, re-imported my OS configuration and all my settings restored just fine.  But afterwards my Vera no longer pulled the proper status from the OS and it couldn't control it either.  Even after restarting both the OS and Vera it still didn't work.  The solution I found was to simply change my OpenSprinkler password in the OS app or web interface, then re-save it.  Then they started talking again.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on May 19, 2015, 11:00:31 am
Upgraded today... seems to be working great.  As i'm on U15 still, i didn't upload the v17 jason file. (right?)

one thing that is off. on the main OS device, i have the enable and disable buttons, and they are controlling the OS perfectly.  But they are not reflected the actual "state" of the device after selection.  They remain grey, no matter which choice i currently have selected. 

any ideas?

I finally got my sprinklers turned on, and started running today.  I can confirm that neither the master (enable/disable) or the individual sprinklers report their actual states when operating. Buttons all work, but no indication in the UI that they are on/off.  any help greatly appreciated.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: MLabuda on May 19, 2015, 03:10:12 pm
I finally got my sprinklers turned on, and started running today.  I can confirm that neither the master (enable/disable) or the individual sprinklers report their actual states when operating. Buttons all work, but no indication in the UI that they are on/off.  any help greatly appreciated.

What is your RefreshStatusSec variable set to? Are there any errors in the Vera log?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on May 19, 2015, 04:43:49 pm
I finally got my sprinklers turned on, and started running today.  I can confirm that neither the master (enable/disable) or the individual sprinklers report their actual states when operating. Buttons all work, but no indication in the UI that they are on/off.  any help greatly appreciated.

What is your RefreshStatusSec variable set to? Are there any errors in the Vera log?

RefreshStatusSec is set to 30.  But i'd assume that if you changed a state directly from the dashboard, the refresh status of button state would be instant, no?  (this worked fine before i upgraded).

Attached is a log snippet. I ran a zone direction from U15, then turned off from U15. 
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: MLabuda on May 19, 2015, 08:54:52 pm
When I run a zone manually from Vera it can take several seconds for the button state in the Vera UI to reflect the change.  Not sure if it waits for the next refresh or not, but either way it definitely shouldn't take more than 30 seconds and shouldn't be greyed out.

What firmware version do you have on your OpenSprinkler?  Are you using the plugin from the app store or did you upload the files from the first post in this thread?

Also, I'm not on expert on this plugin but I don't see anything in your log related to the OpenSprinkler.  Are you viewing your log remotely or from your LAN?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on May 19, 2015, 10:51:17 pm
When I run a zone manually from Vera it can take several seconds for the button state in the Vera UI to reflect the change.  Not sure if it waits for the next refresh or not, but either way it definitely shouldn't take more than 30 seconds and shouldn't be greyed out.

What firmware version do you have on your OpenSprinkler?  Are you using the plugin from the app store or did you upload the files from the first post in this thread?

Also, I'm not on expert on this plugin but I don't see anything in your log related to the OpenSprinkler.  Are you viewing your log remotely or from your LAN?

I overwrote the app store version after upgrading to 2.1.3 with the files from the beginning of this post. 

Interesting .. I noticed an weird reoccurring line in my logs that I posted a question about in another thread. 
LuaInterface::CallFunction_Timer-5 function poll_status_cycle failed [string "..."]:365: attempt to call field 'decode' (a nil value) <

One suggestion was that it might have something to do with the Etherrain plugin.  On that thought, I ran the logs again, and disabled OS from the U15 dash, and saw this line.  makes me think they are now connected. 
LuaInterface::CallFunction_Job device 148 function SOpenSprinkler1_OpenSprinkler1_SetModeTarget_job failed [string "..."]:365: attempt to call field 'decode' (a nil value) <0x2b950000>
01   05/19/15 19:38:49.145   Lua_Job::Run job#882 : dev:148 (0x24eaff0) P:50 S:0 failed <0x


Lots of info in the logs I don't understand, but looks like something is not working. 

And yes, I was logging in remotely earlier, but am now home.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: MLabuda on May 19, 2015, 11:21:07 pm
Yeah there seems to be a communication problem somewhere.  I noticed that your logs don't show that it is polling the OS, or at least not successfully.  If you go to the advanced tab of the OS Controller device in Vera, do you have the IP and MAC address in there?

Just for reference, every 30 seconds (because that is my refresh interval) I have this in my log:

Code: [Select]
50      05/19/15 15:34:24.101   luup_log:96: OpenSprinkler: Debug: poll_status_cycle : Enter <0x2f5d7680>
50      05/19/15 15:34:24.101   luup_log:96: OpenSprinkler: Debug: poll_status : Enter : DeviceID: 96 <0x2f5d7680>
50      05/19/15 15:34:24.119   luup_log:96: OpenSprinkler: Debug: os_http_call: statusCode=200, resp={"devt":1432049660,"nbrd":1,"en":1,"rd":0,"rs":0,"rdst":0,"loc":"pws:[REDACTED]","wtkey":"[REDACTED]","sunrise":362,"sunset":1241,"eip":845188410,"lwc":1432049005,"lswc":1432049005,"sbits":[0,0],"ps":[[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0]],"lrun":[6,1,558,1432011163]} <0x2f5d7680>
50      05/19/15 15:34:24.129   luup_log:96: OpenSprinkler: Debug: poll_status: resp=table: 0x14b2498 <0x2f5d7680>
50      05/19/15 15:34:24.140   luup_log:96: OpenSprinkler: Debug: os_http_call: statusCode=200, resp={"sn":[0,0,0,0,0,0,0,0],"nstations":8} <0x2f5d7680>
50      05/19/15 15:34:24.143   luup_log:96: OpenSprinkler: Debug: poll_status: resp=table: 0x1417e78 <0x2f5d7680>
50      05/19/15 15:34:24.143   luup_log:96: OpenSprinkler: Debug: poll_status: number of program data = 9 <0x2f5d7680>
06      05/19/15 15:34:24.143   Device_Variable::m_szValue_set device: 96 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: ModeStatus was: Enable now: Enable #hooks: 0 upnp: 0 v:0xb6aef8/NONE duplicate:1 <0x2f5d7680>
06      05/19/15 15:34:24.144   Device_Variable::m_szValue_set device: 96 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: StatusMessage was: Idle now: Idle #hooks: 0 upnp: 0 v:(nil)/NONE duplicate:1 <0x2f5d7680>
50      05/19/15 15:34:24.144   luup_log:96: OpenSprinkler: Debug: poll_status: Max Stations: 8 <0x2f5d7680>
06      05/19/15 15:34:24.145   Device_Variable::m_szValue_set device: 96 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: Status was: 0 now: 0 #hooks: 0 upnp: 0 v:0xb6aeb8/NONE duplicate:1 <0x2f5d7680>
50      05/19/15 15:34:24.148   luup_log:96: OpenSprinkler: Debug: poll_status : Exit <0x2f5d7680>
50      05/19/15 15:34:24.148   luup_log:96: OpenSprinkler: Debug: poll_status_cycle : Exit
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on May 19, 2015, 11:24:38 pm
Yeah there seems to be a communication problem somewhere.  I noticed that your logs don't show that it is polling the OS, or at least not successfully.  If you go to the advanced tab of the OS Controller device in Vera, do you have the IP and MAC address in there?

Just for reference, every 30 seconds (because that is my refresh interval) I have this in my log:

Code: [Select]
50      05/19/15 15:34:24.101   luup_log:96: OpenSprinkler: Debug: poll_status_cycle : Enter <0x2f5d7680>
50      05/19/15 15:34:24.101   luup_log:96: OpenSprinkler: Debug: poll_status : Enter : DeviceID: 96 <0x2f5d7680>
50      05/19/15 15:34:24.119   luup_log:96: OpenSprinkler: Debug: os_http_call: statusCode=200, resp={"devt":1432049660,"nbrd":1,"en":1,"rd":0,"rs":0,"rdst":0,"loc":"pws:[REDACTED]","wtkey":"[REDACTED]","sunrise":362,"sunset":1241,"eip":845188410,"lwc":1432049005,"lswc":1432049005,"sbits":[0,0],"ps":[[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0]],"lrun":[6,1,558,1432011163]} <0x2f5d7680>
50      05/19/15 15:34:24.129   luup_log:96: OpenSprinkler: Debug: poll_status: resp=table: 0x14b2498 <0x2f5d7680>
50      05/19/15 15:34:24.140   luup_log:96: OpenSprinkler: Debug: os_http_call: statusCode=200, resp={"sn":[0,0,0,0,0,0,0,0],"nstations":8} <0x2f5d7680>
50      05/19/15 15:34:24.143   luup_log:96: OpenSprinkler: Debug: poll_status: resp=table: 0x1417e78 <0x2f5d7680>
50      05/19/15 15:34:24.143   luup_log:96: OpenSprinkler: Debug: poll_status: number of program data = 9 <0x2f5d7680>
06      05/19/15 15:34:24.143   Device_Variable::m_szValue_set device: 96 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: ModeStatus was: Enable now: Enable #hooks: 0 upnp: 0 v:0xb6aef8/NONE duplicate:1 <0x2f5d7680>
06      05/19/15 15:34:24.144   Device_Variable::m_szValue_set device: 96 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: StatusMessage was: Idle now: Idle #hooks: 0 upnp: 0 v:(nil)/NONE duplicate:1 <0x2f5d7680>
50      05/19/15 15:34:24.144   luup_log:96: OpenSprinkler: Debug: poll_status: Max Stations: 8 <0x2f5d7680>
06      05/19/15 15:34:24.145   Device_Variable::m_szValue_set device: 96 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: Status was: 0 now: 0 #hooks: 0 upnp: 0 v:0xb6aeb8/NONE duplicate:1 <0x2f5d7680>
50      05/19/15 15:34:24.148   luup_log:96: OpenSprinkler: Debug: poll_status : Exit <0x2f5d7680>
50      05/19/15 15:34:24.148   luup_log:96: OpenSprinkler: Debug: poll_status_cycle : Exit

yep... both are there.  and it works, so i'm assuming they are right.  :)
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: MLabuda on May 19, 2015, 11:40:58 pm
Just to play devil's advocate here...
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on May 19, 2015, 11:56:28 pm
Just to play devil's advocate here...
  • Do you have akbooer's JSON parser uploaded (described in first post)?
  • Even though you are on UI5, try uploading all three files again. I'm also on UI5 but I uploaded them all just in case.

DUDE.  My hero!!!!  I had evenwatcher installed, so just blindly assumed his parser was loaded.  Nope.  Just did it. Error all gone.  I'll keep an eye on it, but I think that's it. AND... the buttons all show state correctly (and fast) now!

Thanks so much!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: MLabuda on May 20, 2015, 01:10:37 am
No problem!  I'm glad you got it working.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: virtus on June 10, 2015, 04:49:23 pm
Does this plugin support authentication? My OpensprinklerPi is running the latest version, but it's set up with authentication (prompts you for a username and password) in addition to OpenSprinkler's own password. The plugin is giving me the following error: Unable to communicate with OpenSprinkler controller. Check IP Address.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: automationKing on June 23, 2015, 10:44:41 am
It does, but you need to store the hashed value of the password in the plugin.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: impmonkey on June 28, 2015, 05:38:43 pm
Having some issues getting this plugin to connect.
I have all the necessary files uploaded, just can't seem to get it to connect.
I have tried changing the password back to the default along with using the ignore password option.
Here is the debugging error when it tries to pull the zone update:
50      06/28/15 17:31:03.287   luup_log:3: OpenSprinkler: poll_status from /jo query FAILED: message: Connection Issue __LEAK__ this:8192 start:1216512 to 0x1157000 <0x2c381680>


OpenSprinkler 2.1.5(1) (IP: 10.10.10.14:80)
Veralite Ui5, AKB-json.lua, and updated files for the plugin from this thread.

Ultimately I would like to update the password to something besides the default, but I am a bit confused on updating the XML with the new MD5 hash.

Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: jchiar on June 29, 2015, 05:56:57 pm
I modified the ip and port for my OSPi  192.168.0.137:8082

However when i click enable I get

OpenSprinkler : Error enabling/disabling controller: Bad Status Code: 401


Any idea?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: jchiar on June 29, 2015, 11:51:44 pm
Was running ospi, not united firmware. Now I am.

I can turn on the valve manual, but there still seems to be a disconnect between communication.
I get this message when I click enable or turn on a zone:
Can't detect device

Any idea?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Moshman on July 01, 2015, 01:26:21 am
Hello,

I am getting "device not ready" when I hit "enable". I have followed this post perfectly and read every thing twice. Any ideas?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Moshman on July 08, 2015, 03:12:29 pm
I have Open Sprinkler h/w version 2.3 & s/w version 2.1.5. I still can not determine why I am getting "device not ready" when I try to use this plugin.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: jchiar on July 08, 2015, 10:53:35 pm
Same issue here with 2.1.5 unified firmware
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Mai Pensato on July 29, 2015, 04:34:59 pm
Hi,

I think about buying an OpenSprinkler controller (new DC version) to replace my Rainbird STP6 rain controller. So I will be able to control my garden  sprinklers and drippers via App/smartphone. Also the Rainbird is rather limited: maximum 4 x per day, only 1 zone at a time.  I also have a Vera 3 with lots of Zwave and 433mhz devices and plugins, so an advantage is to integrate  OpenSprinkler with my domotica system using this plugin.

I read that several Vera users already have an OpenSprinkler but often you encounter problems,

My questions to you:
1) How does OpenSprinkler function (apart from Vera): is it working reliable, enough possibilities to make programs like different frequencies and durations per zone ?
2) Does the Vera plugin work with the OpenSpinkler systems with the newest firmware (last 2 posts suggest it does not work anymore ?)
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kyle.dawson on July 29, 2015, 05:22:17 pm
I have used it for last few months.  The device works great, lots of options and nice app on android and chrome web app for desktop. I use the app for most interactions.  But I do like that it works with vera, when I am away from home, I can quickly control it without adding new hole in my firewall.  There are a few issues that I ran into:

1)  I got the raspberrypi version and wifi dongle.  Issue keep it connected.  It not opensprinkler issue, more with dongle/pi.  Work around, I added cron task every min, to ping host to keep it alive.
2) The vera part works if you follow instructions, except password for me.  I had to disable password in OpenSprinkler UI.  Once I did that, works great. Since device is not on internet, not issue for me.

Kyle
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Mai Pensato on August 03, 2015, 09:09:35 am
Thanks Kyle !  Any other experiences with Opensprinkler and Vera 3 or Vera Lite with UI5 ?  I live in Europe (Holland) and I have to buy from USA, so costs are quite high. I have to be sure this works good.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: robertgabrielson on August 11, 2015, 02:56:58 am
Same issue here with 2.1.5 unified firmware

See the OP.  Must install json. 

Because the new firmware for OS returns everything in JSON, I opted to use akbooer's JSON parser library.  You will need to install this to /usr/lib/lua (usually done via scp or sftp).  If you use any of akbooer's other programs/plugins, you may have it installed already.  You can get the file from here.  That's the official thread for the parser and the latest version will be available there.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: JBeukman on August 31, 2015, 04:09:53 am
Hi All I have just recently purchased the veraedge and also the opensprinkinker control unit (not rasberry pi version)
I am not that technical - Is there any body that can assist me to install my opensprinkler control unit with my veraedge - I have the latest version of firmaware installed on both

I loaded the plugin but it just displays two zones and does not allow me to select on or off at all - Is there anybody with complete instructions on how to successfully install this

Really desperate!!

Many thanks
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: kraka40 on September 03, 2015, 07:52:38 pm
Just a shout out and thanks for making these modifications.  They were great with a new UI7 Vera and OS device.  Also a great way for me personally to start learning how to mod the system.

Thanks!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: AAD2 on September 07, 2015, 09:17:01 am
Hey everyone... I followed the instructions on the first page, and my Vera Edge keeps telling me "Can't detect device" when I press enable.

I have the Enable/Disable buttons visible, so I think that my upload of the files went ok. Any thoughts on what I should try? Can I upload any info to help figure out where I went wrong?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: johnes on September 17, 2015, 11:17:33 am
Is there any way to turn the debug logging off?  95% of my log is opensprinkler...

Sure, at the top of I_OpenSprinkler1.xml you will see something like this:

Code: [Select]
  local TASK_HANDLE = nil
  local PW = ""
  local HASHEDPW = nil
  local MSG_CLASS = "OpenSprinkler"
  local DEBUG_MODE = true

Just change the DEBUG_MODE variable to "false" and it turns off the debug logging.  Upload the file after changing it and restart luup and it will be set.

Since most people seem to be working fine with the current code, I'll probably make that change myself and post it here soon.  There might be quite a bit of non-debug logging as well.  If you still feel it's a bit too verbose for you, then let me know and I'll see if I can move some of that into debug output.

Bruce

Hi Bruce -

Wondering if you can help me figure out how to get the logging to a minimum.  Even with debug turned off, I still get so much that I ended up uninstalling for the time being because it makes troubleshooting other stuff really difficult.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: ashsav on September 19, 2015, 05:10:52 am
love the plugin, just got it somewhat working... opensprinkler web interface responds to changes made via vera, but status is failing, buttons take a long time to update around 1min, sometimes not at all... get an error via web log of
luup_log:141: OpenSprinkler: poll_status from /js query FAILED: message: Invalid JSON Returned <0x2e393680>
any tips would be greatly appriciated
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tbully on October 17, 2015, 03:16:17 pm
Just upgraded my firmware and plugin. I had to change some PLEG logic due to the new enable/disable state, etc.  All is well except the zone names......  Is there any way to manually name the zones?  Vera/plugin automatically prepends OpenSprinkler followed by the zone name/number.  This is unreasonably long, especially in the mobile apps. 

Thanks.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tbully on October 18, 2015, 01:25:29 pm
Just upgraded my firmware and plugin. I had to change some PLEG logic due to the new enable/disable state, etc.  All is well except the zone names......  Is there any way to manually name the zones?  Vera/plugin automatically prepends OpenSprinkler followed by the zone name/number.  This is unreasonably long, especially in the mobile apps. 

Thanks.

As an update, in I_OpenSprinkler1.xml, I changed the "--Set the zone name"

from:
luup.attr_set('name', 'OpenSprinkler ' .. singleZoneName .. "(S" .. s .. ")", lul_zone_device)

to:
luup.attr_set('name', "Zone-" .. s .. " " .. singleZoneName , lul_zone_device)

....to fit my needs.

Thanks.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: aurora912 on November 08, 2015, 09:29:23 am
I'm Having a bit of trouble getting the button's to show the actual state of Opensprinkler.

Have so far,

-Installed original OS  (on UI5)
-Uploaded alb-json.lua through the develop apps page or vera, then SSH'd in and mv'd the file to "/usr/lib/lua/akb-json.lua". Double checked with the 'ls' command to see it was there.
-Updated the 3 open sprinkler files

I can see the new buttons, they work, but don't show the actual state and are just light blue.

The vera log keeps repeating the following.

Code: [Select]
01 11/09/15 1:26:17.119 LuaInterface::CallFunction_Timer-5 function poll_status_cycle failed [string "..."]:365: attempt to call field 'decode' (a nil value) <0x2ea27680>
50 11/09/15 1:26:19.101 luup_log:125: OpenSprinkler: Debug: poll_status_cycle : Enter <0x2ea27680>
50 11/09/15 1:26:19.101 luup_log:125: OpenSprinkler: Debug: poll_status : Enter : DeviceID: 125 <0x2ea27680>
50 11/09/15 1:26:19.119 luup_log:125: OpenSprinkler: Debug: os_http_call: statusCode=200, resp={"fwv":216,"tz":92,"ntp":1,"dhcp":1,"ip1":192,"ip2":168,"ip3":0,"ip4":22,"gw1":192,"gw2":168,"gw3":0,"gw4":1,"hp0":80,"hp1":0,"hwv":23,"ext":0,"sdt":0,"mas":0,"mton":0,"mtof":0,"urs":0,"rso":0,"wl":25,"den":1,"ipas":0,"con":150,"lit":100,"dim":15,"uwt":1,"ntp1":50,"ntp2":97,"ntp3":210,"ntp4":169,"lg":1,"mas2":0,"mton2":0,"mtof2":0,"fwm":1,"fpr0":100,"fpr1":0,"re":0,"reset":0,"dexp":0,"mexp":6,"hwt":172} <0x2ea27680>

btw, I just happened to have a few ssh commands written down from playing with a rasp pi, Im not very familiar with this stuff.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: aurora912 on November 08, 2015, 07:57:22 pm
Further to the above. Do I actually have to 'Install' the JSON thing?  I have just moved the file to the directory but haven't done anything further to 'install' it.

Code: [Select]
root@MiOS_XXXXXXX:/usr/lib/lua# ls
akb-json.lua     lmo.so           lxp.so           nixio            px5g.so          ssl
bit.lua          ltn12.lua        mime             nixio.so         socket           ssl.lua
iwinfo.so        luci             mime.lua         profiler.so      socket.lua       ssl.so
lfs.so           lxp              mime.so.1.0.2    px5g             socket.so.2.0.2  uci.so
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: aurora912 on November 15, 2015, 11:53:34 pm
Also Get this error as the vera starts up.

Code: [Select]
15:48:37.975luup_require can't find /usr/lib/lua/akb-json <0x2c1b5680>
But as you can see from above post, the file is there. Really stuck at the moment.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tbully on November 20, 2015, 10:22:06 am
Very little activity in this thread but thought I'd pop back in with a new question.  There seems to be a lot of logging for this plugin in:

/var/log/cmh/LuaUPnP.log

I see things like this very often:
11/20/15 10:20:53.273   Device_Variable::m_szValue_set device: 83 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: ModeStatus was: Disable now: Disable #hooks: 1 upnp: 0 v:0x1294930/NONE duplicate:1 <0x2e785680>

Now, I can see the usefulness of these when debugging but is there a way to quiet these down?

I've already set debug to false in I_OpenSprinkler1.xml.

Thanks!

Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tbully on December 12, 2015, 08:40:33 am
Very little activity in this thread but thought I'd pop back in with a new question.  There seems to be a lot of logging for this plugin in:

/var/log/cmh/LuaUPnP.log

I see things like this very often:
11/20/15 10:20:53.273   Device_Variable::m_szValue_set device: 83 service: urn:fowler-cc:serviceId:OpenSprinkler1 variable: ModeStatus was: Disable now: Disable #hooks: 1 upnp: 0 v:0x1294930/NONE duplicate:1 <0x2e785680>

Now, I can see the usefulness of these when debugging but is there a way to quiet these down?

I've already set debug to false in I_OpenSprinkler1.xml.

Thanks!




Shameful bump.  I know it's not watering season so this may have been missed.

Thanks.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomtcom on February 06, 2016, 01:29:07 pm
I'm deciding on getting OpenSprinkler for my birthday this March. Last time I posted here was a year ago. Anyone still finding this plugin is working good, stable?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: integlikewhoa on February 06, 2016, 07:43:50 pm
I'm deciding on getting OpenSprinkler for my birthday this March. Last time I posted here was a year ago. Anyone still finding this plugin is working good, stable?

I never use it but appears to be working. I really haven't found much in need of "AUTOMATION" for spinklers.

Some people said to lock out during a party, but I have my sprinklers for early in morning only on weekdays. I never have a party going on at 6am.

If i need a manual override I open the Open-sprinkler App and put a manual rain delay on for a day or two or what ever. 
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tomgru on February 07, 2016, 01:22:34 pm
Same.... app works great.... and original installed it to use with the virtual rain sensor to adjust use during rainfall, which was awesome!

But they updated the OS app to do that as well, and after awhile, I realized I really wasn't using the plugin any longer.  Figured with all the memory and plugin problems we all seem to experience from time to time, just made sense to uninstall.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: aurora912 on March 23, 2016, 02:44:22 am
Still really after some help with my posts 1 page back. Can't work out how to the the current status to report to Vera.

I'm sure I haven't got the akb-json thing installed properly but don't know why.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: aurora912 on March 23, 2016, 05:15:56 am
^ Disregard the above. Finally worked out how to install akb-json

Used the following in a terminal command. For some reason this worked but when I moved the file via ssh it didn't.

scp /local/path/to/akb-json.lua root@your.vera.ip.address:/usr/lib/lua/
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: johnes on May 02, 2016, 03:03:27 pm

Next you should backup the files that we are about to overwrite.  Go to Apps->Develop Apps->Luup Files and download the following three files:
I_OpenSprinkler1.xml
D_OpenSprinkler1.json
D_OpenSprinkler1_UI7.json


Are there plans to update the opensprinkler plugin in the app store with these changes?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: CourtK on May 23, 2016, 08:35:41 pm
^ Disregard the above. Finally worked out how to install akb-json

Used the following in a terminal command. For some reason this worked but when I moved the file via ssh it didn't.

scp /local/path/to/akb-json.lua root@your.vera.ip.address:/usr/lib/lua/

This worked for me too on my UI7 veraplus.  I can see the zone names and no errors are shown.  I had originally used the Apps / Develop Apps / Luup files to upload the akb-json file and then used the mv command to move it to /usr/lib/lua via ssh, but it did not work.  This method also added an lzo to the end of the file name.  Just using an scp command, like aurora912 suggested, from my mac terminal worked.

I don't have a need for scenes, but just another easy method to turn on and off the sprinklers.

CourtK
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: dkaars on May 24, 2016, 06:41:49 pm
Hi brucehvn

I followed what you said and seem to still be having trouble.
Wondering if you might know.

I am using UI5 and recently purchased opensprinkler... think it has firmware 2.3.
When I install the app I get a device with 3 icons like mentioned and 2 other devices (zone 1 and zone2).
No buttons work.. you can't even click on them.

I have updated the files and the buttons have changed but still can't click on them.
I have tried with and without a password in the opensprinkler UI but same results.

Have you seen this in your testing?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: gabe.wieskamp on June 02, 2016, 07:11:13 am
Does anyone know how to modify the names it brings in every Luup restart?

It adds "Opensprinkler" + OSName + "(" + OS ID + ")" and the names are simply too long...
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: johnes on June 28, 2016, 02:18:54 pm
I am using DataMine2 and EventWatcher, but when I run OpenSprinkler on 7 of my zones, it shows status changes for zone 1, 2, and sometimes 3, but never reports status changes for the other zones.  I am wondering if this is because one starts when the other stops?  Or some other issue?

I don't think it's an EventWatcher/DataMine2 issue...

Can anyone help?

Thanks!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: seanh on July 22, 2016, 12:37:02 am
Upgraded to Vera Firmware 7.15.  Now getting Can't detect device errors whenever I change an OpenSprinkler device (on/off on zone, enable/disable on controller).  Also, Opensprinkler is getting the commands and executing, but Vera isnt updating the status, so when I turn on a zone, I dont see the status change on the UI.  Anyone else having these issues?  Anyway to resolve?

Thanks,
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: tbully on December 17, 2016, 05:09:38 pm
Does anyone know how to modify the names it brings in every Luup restart?

It adds "Opensprinkler" + OSName + "(" + OS ID + ")" and the names are simply too long...

Old thread.  Still trying to get logging to a minimum but saw your problem.  I solved it one page back:

Just upgraded my firmware and plugin. I had to change some PLEG logic due to the new enable/disable state, etc.  All is well except the zone names......  Is there any way to manually name the zones?  Vera/plugin automatically prepends OpenSprinkler followed by the zone name/number.  This is unreasonably long, especially in the mobile apps. 

Thanks.

As an update, in I_OpenSprinkler1.xml, I changed the "--Set the zone name"

from:
luup.attr_set('name', 'OpenSprinkler ' .. singleZoneName .. "(S" .. s .. ")", lul_zone_device)

to:
luup.attr_set('name', "Zone-" .. s .. " " .. singleZoneName , lul_zone_device)

....to fit my needs.

Thanks.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on April 07, 2017, 02:30:19 am
not sure if anyone still working on this - i have ospi version 2.1.7 - and UI7 i can control the valves but i get and error message 

"OpenSprinkler : Error enabling/disabling controller: Connection Issue"


The valves change and they update in the ui but i just have that blue bar across the top of the  vera with that error message 
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: pls90 on April 09, 2017, 01:44:03 pm
I followed the instructions from the first post to word but seem to be unable to enable the sprinkler devive
I get
Code: [Select]
OpenSprinkler : Error enabling/disabling controller: Bad Status Code: 404I wonder if the password has to be md5 hashed.
I tried entering the plain string and also the md5 hash.
Any ideas as to what I could try?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on February 21, 2018, 04:29:37 am
any update?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 01, 2018, 05:20:02 am
I take it that the lack of replies here says this add-on is dead?
If so, it does not make sense to have an add on in the store that does not work. Can we get the developer to update it or remove it?

The only thing I am able to do with this add on V1.4 and Open Sprinkler V2.17(1) is disable and enable Open Sprinkler via Vera. Turning the Zones on or off does not work.
I will try to get this to work.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 01, 2018, 08:32:02 am
Me and a friend got it working again, with right icons, device categories and so on.
If the code license allows it, I'm more than happy to take ownership.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: bwillette on June 01, 2018, 09:07:36 am
Me and a friend got it working again, with right icons, device categories and so on.
If the code license allows it, I'm more than happy to take ownership.

I?d be interested in the updates if you wouldn?t mind posting them.

Thanks!
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 01, 2018, 12:03:39 pm
Me and a friend got it working again, with right icons, device categories and so on.
If the code license allows it, I'm more than happy to take ownership.
Awesome!
Yes please let us know how you did this.

BTW, I messaged brucehvn to see if he was still interested in this add on. Hopefully he will respond here so we can get this add on working again.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 01, 2018, 02:35:30 pm
You just need to change a couple of api calls.
Other things are just cosmetic.
If the original author is OK, I'd post the files and update the store.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 02, 2018, 01:57:38 pm
You just need to change a couple of api calls.
Other things are just cosmetic.
If the original author is OK, I'd post the files and update the store.

Not sure if the author is going to respond. Do you mind if I can get that info from you directly?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 02, 2018, 02:10:34 pm
I'm out of town for a short break. I'll be back on Monday and I'll post the files.
Long term I think it'd be better if we fix the store listing.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on June 02, 2018, 04:11:05 pm
nice can u please upload the files u used so we could try it
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on June 03, 2018, 02:26:18 am
You just need to change a couple of api calls.
Other things are just cosmetic.
If the original author is OK, I'd post the files and update the store.

yeah base of my research the problem was with the calls 202 and something like that  -- the response the the plugin was looking for was changed in the open sprinker update but i just never knew how to fix .. kudos
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 04, 2018, 12:02:59 pm
I'm out of town for a short break. I'll be back on Monday and I'll post the files.
Long term I think it'd be better if we fix the store listing.

Great. Anything I can do to help, please let me know.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 07, 2018, 03:30:37 am
Get the files from https://github.com/dbochicchio/vera

I modified the original version that has not license attached to it. If the original author prefers to remove the files, I will do it.

No support for it, it-works-on-my-machine and similar disclaimers apply.

Feel free to fork to improve it.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 08, 2018, 03:14:19 pm
Get the files from https://github.com/dbochicchio/vera

I modified the original version that has not license attached to it. If the original author prefers to remove the files, I will do it.

No support for it, it-works-on-my-machine and similar disclaimers apply.

Feel free to fork to improve it.

Thanks for your help with this but after uploading the 2 files, I get a lua startup failure.
Any thoughts?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 08, 2018, 03:43:43 pm
Try to create the device from scratch. I never tried to update old files.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on June 09, 2018, 01:23:01 pm
looks nice but broke my vera plus 2 times
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on June 09, 2018, 11:13:40 pm
doesnt give the option to configure the connectivity to open sprinkle
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 10, 2018, 08:29:15 am
You have to set the variables as per the original plugin.
I'm busy finishing a new book, but I'll take a look and write a guide in the next weeks.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on June 10, 2018, 09:02:16 am
v1?
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 13, 2018, 02:25:15 pm
You have to set the variables as per the original plugin.
I'm busy finishing a new book, but I'll take a look and write a guide in the next weeks.

Thanks again. Anything I can do to help, let me know.

In the mean time. I have managed to get Vera to operate the OS controller (Disable/Enable) and it's outputs (Valves) (On/Off) but unfortunately there is still no feedback on status of the OS controller or any of the outputs.
To do this I had to completely delete the OS add on and follow the first post on this thread.
http://forum.micasaverde.com/index.php/topic,29977.0.html

I ended up with the following and I can now enable and disable the OS controller and turn on and off any of the valves connected to that controller.
Remember the valves will turn on and then automatically off for the predetermined time set in the Variables tab called "ManualMaxMinutes" or you can turn them off before that time set via a scene or manually.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on June 13, 2018, 02:46:28 pm
Great. I forgot to commit a new version with local icons. I'll do next day since I'm travelling again.

If you are able to write a small manual, feel free to make a pull request or send it to me directly and I'll publish it.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Jamr on June 25, 2018, 02:36:06 pm
Great. I forgot to commit a new version with local icons. I'll do next day since I'm travelling again.

If you are able to write a small manual, feel free to make a pull request or send it to me directly and I'll publish it.

Everything is already documented on the first post to this thread, or the link I provided.
If there is anything I can further do, please let me know.
Thank you for your effort here.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: helraiser on June 27, 2018, 06:33:43 am
Yep, I've been struggling trying to get this working and using the instructions from the first post and well... no bueno.

I tried installing the original app, overwriting the files mentioned in the first, and then uploading the two files from this most recent modification. Nothing works however.

As a final resort, I uploaded all the files in the most recent update and that just about killed Vera :) Luckily I was able to uninstall the app and reinstall it. still no luck getting this working.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: RichieB on June 28, 2018, 08:29:11 pm
yeah it killed my vera as well === it loads abou 35 valves / zones that kills the vera
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: helraiser on June 28, 2018, 09:39:43 pm
I found you're supposed to put the password (not sure if it's the hashed or clear text) into the I_OpenSprinkler1.xml file. Problem is I did that and it wouldn't work. I did get it working once after I disabled the password on the controller but then I had to deny internet access to the controller.

When I went to start modifying the sprinkler names that killed it and now I can't get it to communicate again. Been struggling with it since without making any file changes.

Edit: Got it working in UI7 on my Veraplus, with md5 hashed password and 6 zones

1. Install the opensprinkler app and let it install the controller
2. Add your IP to the device. Under Advanced - Variables, add your zones (2 are added by default)
3. If yours works, abort. Proceed no further! For most though, it won't work.
4. Upload the 3 files from the first post in this thread.
5. Note, the I_OpenSprinkler1.xml file will be uploaded again later but with the password modification
6. Ensure your OS controller has "Ignore Password" enabled. At this point,
7. Open the 2 files from therealdb's github (D_OpenSprinkler1_UI7.xml and D_OpenSprinkler1_UI7.json)
8. In Vera, go to the controller's property and click Advanced. Change the device_file to D_OpenSprinkler1_UI7.xml
9. Reload
10. You should be ready to rock at this point.

To restore security

1. Uncheck "Ignore Password" on your controller
2. Open up "I_OpenSprinkler1.xml" in notepad or a true xml editor (this tripped me up till i just used a plain text editor)
3. Look for the line "HASHEDPW = md5(PW)" and change md5(PW) to your hashed password in quotes
4. for example: HASHEDPW = "bj289hgkadjfjashggjio2"
5. To generate a hash I'd recommend doing it offline using an app but there are online generators too
6. Save and upload the file

Done.

Now I just wish I could use these as a light switch so I could integrate them into Alexa, Google, or Homekit. I've got the older OS2.2 which doesn't support IFTT. Although, now that it's in Vera...
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on July 09, 2018, 02:37:09 pm
I didn't tried with my Alexa, but it should work if you change category_num (3) and subcategory_num (3) to your device and do a rediscovery again.
Remember to not use all lights on/off, becuase you will change your spinklers status as well.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: shapshere on February 01, 2019, 11:56:01 am
Will this be updated in the app section or do we have to manually install it?

Thank You
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: Viruta57 on March 11, 2019, 02:53:33 am
I don't understand this one....
"Open the 2 files from therealdb's github (D_OpenSprinkler1_UI7.xml and D_OpenSprinkler1_UI7.json)"
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on March 11, 2019, 03:45:10 am
Will this be updated in the app section or do we have to manually install it?

As I don't own the code and no license was attached, I simply fixed it and uploaded on my GitHub with no guarantee I'll work, etc. Unfortunately the original author seems to not reply to questions about this plugin, so I cannot "officially" take ownership of it.
Title: Re: OpenSprinkler Plugin Update for firmware 2.1.3+
Post by: therealdb on March 11, 2019, 03:56:37 am
I don't understand this one....
"Open the 2 files from therealdb's github (D_OpenSprinkler1_UI7.xml and D_OpenSprinkler1_UI7.json)"

this is not necessary, if you set the proper variable via UI/LUA.