OpenSprinkler › Forums › Hardware Questions › OpenSprinkler Pi (OSPi) › Interval Program V2.0.1 available
- This topic is empty.
-
AuthorPosts
-
June 23, 2014 at 9:27 pm #22994
Dan in CAParticipantThis release includes:
1. A fix for the irrigation timeline on the Home page
2. The addidion of a “Plugins” button to the Home page
The timeline display
The Home page irrigation timeline had several problems that could not be easily fixed by a simple tweak of the code. It required a full-on “function transplant”.
Because I did not write the code for the new UI, it took a bit of time to figure out how things work. The curent update seems to be doing much better now but still needs some additional work to implement a display of Master valve operation.While digging around in the code for the timeline I found a feature that has not been fully documented before.
The irrigation timeline actually displays data from two different sources:
Irrigation events that are scheduled and are either currently running or scheduled for a future time are shown as markers with white stripes. This data is generated by a simulation of the Interval program’s operation. if you click the “Next Day >>” button on the timeline you will be viewing a full simulation of the irrigation programs you have defined for that day.
Irrigation events that have already occurred will only be shown if logging is enabled and solid color event markers are created from log data. If you have logging enabled and click the “<< PREV DAY" button on the timeline you will actually be viewing a graphical representation of the log data.
when you are viewing the current day’s timeline (the default view), you are seeing a combination of the two data sets.
The new Plugins button
The Plugins button opens a drop-down menu with links to plugin URLs.
A link can point to a web page containing user controls, displays, more links, etc, like the “Monthly Adjust” example plugin, or it can point to a Python class in your plugin that causes some action to occur like the “Test Relay” example.If you are writing a plugin and want to add it to the menu, you will need to have imported the “gv” module into your plugin. You may have already done this since the gv module provides access to all of the Interval program’s settings and other “global variables” as described in the gv_reference.txt file in the OSPi directory.
With that in place, you only need to add one line of Python code to your plugin like so:
gv.plugin_menu.append()
where:
- ‘Menu Text’ is the name of your plugin or other text you want to appear on the menu and,
‘url’ is a URL for the link.With this line added, somewhere near the top of your plugin, it will be automatically added to the menu when the plugin is loaded.
In the “Monthly Adjust” example plugin the line is:gv.plugin_menu.append()
The menu is not yet styled and is rather crude looking but I wanted to get the basic functionality in place and available for use. There are some other changes to the program in the works and time is limited so I will leave the UI styling to others.
To update to this version from GitHub
It is recommended that you use the “fetch – reset” method rather than a simple “pull” ie:
#make sure you are on the master branchgit checkout master
#fetch the new version form GitHub
git fetch
# reset to the new version
git reset --hard origin/master
Once the update has been completed, reboot the system
or
if you are using the init.d script contributed by Denny Fox:
http://rayshobby.net/mediawiki/index.php?title=Python_Interval_Program_for_OSPi#An_alternate_method:
restart the program with:sudo service ospi restart
If you are updating from a pre-v2.0 rev, this update method is required.
Dan
June 24, 2014 at 12:34 am #27320
scottshParticipantAwesome new Plug-in UI code! I was driving home tonight thinking that this was needed. I’m working on porting my plug-in over now.
June 24, 2014 at 3:04 am #27321
AlanParticipantDan,
After I upgraded to the latest version, I noticed that the timeline is not displaying the Odd/Even day programs correctly. I have my program set for even days, yet the timeline is showing it on the odd days.
June 24, 2014 at 3:14 am #27322
Dan in CAParticipantThanks.
I’ll check it out. That should be an easy one to fix.
Dan
June 24, 2014 at 1:13 pm #27323
eecycloneParticipantI have a 3 day cycle with program 1 set to run on day 1, program 2 on day 2, and program 3 on day 3. The log shows that program 1 ran yesterday morning and program 2 ran this morning. However, the timeline shows program 2 running tomorrow, Thursday, Friday, and so on… The mobile app shows the program preview as cycling correctly through the 3 programs every 3 days. I don’t have any ideas why this would be but I wanted to report the issue.
June 24, 2014 at 3:22 pm #27324
Dan in CAParticipanteecyclone ,
This could be the same problem Captn Avenger reported. Your reports provides a valuable clue about the possible cause.
Thanks.
Dan
June 24, 2014 at 4:07 pm #27325
eecycloneParticipant@Dan in CA wrote:
eecyclone ,
This could be the same problem Captn Avenger reported. Your reports provides a valuable clue about the possible cause.
Thanks.
Dan
Also if it helps, the program preview was not doing this until I updated to 2.0.1. The programs were showing up fine in 2.0.0. My program preview issue with 2.0.0 was with sequencing (if I set programs 1, 2, and 3 to run on the same day, they would all show as running at the same time) However, sequencing in program preview is fixed with 2.0.1. I did a little bit of testing, and when I have the interval set to start in 1, or 2 days, the program preview does not display. It is only able to be previewed when the interval start in setting is set to be starting in 0 days. Let me know if you need me to explain what works and doesn’t work more clearly.
June 25, 2014 at 12:17 am #27326
Dan in CAParticipantThat helps.
I am testing the updated code and have found some possible problems.
Dan
June 25, 2014 at 12:32 am #27327
prbParticipantIn addition to the problems outlined above in 2.0.1 I’m also seeing this:
I have recurring programs defined to start at 06:00 and running until 09:00 and running with an interval of 1 hour for a duration of 15 minutes. Previous to 2.0.1 this would run the zone 3 times for 15 minutes each. Now the homepage preview shows these programs running 4 times with an additional run starting at 09:00.
– paul
June 25, 2014 at 1:09 am #27328
Dan in CAParticipantPaul,
Thanks for the report. I see the problem and it is fixed for the next update.
Dan
-
AuthorPosts
- You must be logged in to reply to this topic.
OpenSprinkler › Forums › Hardware Questions › OpenSprinkler Pi (OSPi) › Interval Program V2.0.1 available