bruceyeg Posted May 5, 2017 Posted May 5, 2017 Suppose I want my Christmas lights to come on every year between Dec 1 and Jan 10. When I program the schedule in the ISY Admin Console, there is always a year that appear on the calendar with the month where I pick the dates. It seems that I always have to choose a particular year. So if I set up a program to manage my Christmas light for 2016/2017, the lights won't come on next year until I edit the program and change the dates to 2017/2018. I have a lot of events that need to occur every year between certain dates. Having to constantly edit my programs to change the year is getting really annoying. Could you just put in a check box "Every year". Or am I missing a simple trick?
oberkc Posted May 5, 2017 Posted May 5, 2017 You are missing no simple trick. One of the regular forum members has created a relatively complicated set of programs to handle this, but I simply go in every so often and update them. If you are interested in giving it a shot, I found the discussion on the wiki: http://wiki.universal-devices.com/index.php?title=ISY-99i_Generic_Calendar_Using_Programs_and_Variables I agree that this feature would be nice. I understand this is available in SW build 5.X, but it is, apparently, not ready for prime time quite yet.
Bumbershoot Posted May 7, 2017 Posted May 7, 2017 Another option: If you're on firmware 5.x.x and interested/willing to run Nodelink (which I am for other functionality it provides), you can turn on the "ISY Data" node and this problem can be easily solved (see attached screenshot). I've run Nodelink on a Mac Mini and on a RaspberryPi and it's never hiccuped even once on either platform. For me, this is an easy solution. 1
larryllix Posted May 7, 2017 Posted May 7, 2017 (edited) ISY firmware v5.* has other options to generate a date without year internally and self dependant. However v5.* is beta software yet. http://forum.universal-devices.com/topic/17157-more-flexibility-in-schedule-setup/ Edited May 7, 2017 by larryllix
auger66 Posted January 26, 2018 Posted January 26, 2018 (edited) ISY firmware v5.* has other options to generate a date without year internally and self dependant. However v5.* is beta software yet. http://forum.universal-devices.com/topic/17157-more-flexibility-in-schedule-setup/ Just starting a ver 5 ISY setup from scratch. After loading ver 5, I see you still can't specify a date range without a year. That's a little disappointing. In my old place I had to go in every year to change the year on a couple of programs. What is the latest/easiest way to use a date range without a year in ver 5? Thanks Edited January 26, 2018 by auger66
larryllix Posted January 26, 2018 Posted January 26, 2018 (edited) Just starting a ver 5 ISY setup from scratch. After loading ver 5, I see you still can't specify a date range without a year. That's a little disappointing. In my old place I had to go in every year to change the year on a couple of programs. What is the latest/easiest way to use a date range without a year in ver 5? Thanks The best is still as I posted and I still use it with a slight modification. I use two decimal places now so that the value becomes MM.DD, or 12.25 for Christmas. I can post that later if needed. Just follow the same link. https://forum.universal-devices.com/topic/17157-more-flexibility-in-schedule-setup/?p=152606 Edited January 26, 2018 by larryllix
paulbates Posted January 26, 2018 Posted January 26, 2018 If you don't want to go V5, there is a V4 version of the program Bumbershoot referenced too. It puts the information into ISY variables under V4. You can then use the variables in your programs... its the same information you see in the screen shots, but in variables instead of nodes. Month 1 - 12, Day 1 - 31. The even/odd fields are great for things like sprinkler programs where you need to manage to a certain day More info and screen shots here Another option: If you're on firmware 5.x.x and interested/willing to run Nodelink (which I am for other functionality it provides), you can turn on the "ISY Data" node and this problem can be easily solved (see attached screenshot). I've run Nodelink on a Mac Mini and on a RaspberryPi and it's never hiccuped even once on either platform. For me, this is an easy solution. Paul
apostolakisl Posted January 26, 2018 Posted January 26, 2018 Just starting a ver 5 ISY setup from scratch. After loading ver 5, I see you still can't specify a date range without a year. That's a little disappointing. In my old place I had to go in every year to change the year on a couple of programs. What is the latest/easiest way to use a date range without a year in ver 5? Thanks V5 does have it. It just isn't where you think. It is built into system variables. 1) Create a variable and call it "month" 2) Write a program that runs every day at midnight 3) In the "then" clause, set month = sytem variable month. New Program - [ID 014A][Parent 0093] If Time is 12:00:00AM Then $Month = [Current Month (Jan=1, Feb=2, etc.)] Else - No Actions - (To add one, press 'Action') Repeat for other system variables. Then in your if clause you can use those variables. ie if $month = 12 and if $day of month = 25 and if time is 7am Then notify everyone by email 'merry christmas' 1
Goose66 Posted January 26, 2018 Posted January 26, 2018 I just put the date ranges for three or four years in an if statement. Nothing in my home automation systems stays consistent that long anyway, and if it were I would just have a very simple change to make every four years. 1
larryllix Posted January 26, 2018 Posted January 26, 2018 (edited) Here is the program where I use the two decimal places just for looks. MM.DD The three time triggers are just insurance against a power loss or me playing with the program during the time. Note that the scratchpad variable can be Integer but the resultant variable MM.DD must be State in order to trigger the programs that depend on it. Also you need to set two decimal places for them. Set MM.DD - [ID 00B8][Parent 0006] If Time is 12:00:01AM Or Time is 3:00:01AM Or Time is 6:00:01AM Then $sISY.DayOfWeek = [Current Day of Week] $sISY.DayOfMonth = [Current Day of Month] $ISY_Date.scratchpad = [Current Day of Month] $ISY_Date.scratchpad /= 100 $ISY_Date.scratchpad += [Current Month (Jan=1, Feb=2, etc.)] $sISY.MM.DD = $ISY_Date.scratchpad Else - No Actions - (To add one, press 'Action') And this is how the usage looks. The programs do not care what day of the week or year it is. I have many programs for other devices that use the same variable for dates ranges independent of the year. Until V5 I was changing my program times every year but usually when the time comes it was forgotten about and had to be reset after the cycle should have started. Xmas Lights.9' tree - [ID 00BA][Parent 00C0] If ( Time is Sunset + 15 minutes And ( $sISY.MM.DD >= 11.15 Or $sISY.MM.DD <= 1.06 ) ) Or ( Time is 5:00:00AM And $sISY.MM.DD >= 12.24 And $sISY.MM.DD <= 12.26 ) Then Wait 1 second Set 'RecRm Christmas Tree' On Wait 6 hours Run Program 'Xmas Lights.9' tree' (Else Path) Else Wait 1 second Set 'RecRm Christmas Tree' Off Edited January 26, 2018 by larryllix 2
auger66 Posted February 27, 2018 Posted February 27, 2018 (edited) Alright, I wrote/copied this program to get the date without a year. I have one integer variable "scratchpad" and one state "MM.DD" variable. This is about to be a rental property so I can't do my usual trial-and-error method of programming. When I wrote it yesterday, it worked fine after a run-then right click. Today the variables are still showing yesterday's date-- 2.25 I don't see anything wrong with it, but this ISY is connected to a router without internet right now. The ISY date/time is correct using the 24-hour option. Does the ISY have to have an internet connection to grab a system variable? Thanks Edited February 27, 2018 by auger66 typo
kclenden Posted February 27, 2018 Posted February 27, 2018 5 hours ago, auger66 said: Alright, I wrote/copied this program to get the date without a year. I have one integer variable "scratchpad" and one state "MM.DD" variable. This is about to be a rental property so I can't do my usual trial-and-error method of programming. When I wrote it yesterday, it worked fine after a run-then right click. Today the variables are still showing yesterday's date-- 2.25 I don't see anything wrong with it, but this ISY is connected to a router without internet right now. The ISY date/time is correct using the 24-hour option. Does the ISY have to have an internet connection to grab a system variable? Thanks I'm not running V5, so don't know the answer but would find it hard to believe that the ISY would need an internet connection to access system variables. I'd be more likely to believe the program didn't actually run. You don't have the program disabled, do you? Or have it residing in a folder with a condition that would prevent it from running? What's the program's "Last Run Time" listed in the Admin Console? What's its "Status" listed in the Admin Console?
DrLumen Posted February 27, 2018 Posted February 27, 2018 How are you getting at the system variables like [Current Day of Month]? I don't see those options.
Bumbershoot Posted February 27, 2018 Posted February 27, 2018 6 hours ago, DrLumen said: How are you getting at the system variables like [Current Day of Month]? I don't see those options. These are only available in the "Then" and "Else" stanzas. 1
DrLumen Posted February 27, 2018 Posted February 27, 2018 1 hour ago, Bumbershoot said: These are only available in the "Then" and "Else" stanzas. Thanks. I had never seen them before.
larryllix Posted February 27, 2018 Posted February 27, 2018 Thanks. I had never seen them before. Yeah. The system variables are not available directly in logic equations. They have to be assumed into a variable in another program with a sampling loop. Then they can be used for program triggers. Sent from my SM-G930W8 using Tapatalk It should be noted that ISY only has a cheaper hardware based clock and may not keep good time without an occasional online sync.
auger66 Posted February 27, 2018 Posted February 27, 2018 12 hours ago, DrLumen said: How are you getting at the system variables like [Current Day of Month]? I don't see those options. I took me forever to find it, too.
auger66 Posted February 27, 2018 Posted February 27, 2018 13 hours ago, kclenden said: I'm not running V5, so don't know the answer but would find it hard to believe that the ISY would need an internet connection to access system variables. I'd be more likely to believe the program didn't actually run. You don't have the program disabled, do you? Or have it residing in a folder with a condition that would prevent it from running? What's the program's "Last Run Time" listed in the Admin Console? What's its "Status" listed in the Admin Console? You're right; the program was never triggered. But the "if" was so simple, I didn't know why. Plus, it wasn't even running with a "run then" yesterday. It was enabled. I went down today to put 5.12 on and noticed the last run time was correct so I looked at the variables. They were correct today. I poked at it yesterday but didn't change anything. So I don't know why it wasn't running yesterday but is fine today.
kclenden Posted July 13, 2018 Posted July 13, 2018 On 1/26/2018 at 8:58 AM, larryllix said: Here is the program where I use the two decimal places just for looks. MM.DD I liked your idea for using two decimal places for looks until I saw what the ISY does with far right zeros (hint - same thing it does with far left zeros). So the 10th, 20th or 30th of a month ends up as MM.D. Should still work correctly but not as pretty.
larryllix Posted July 13, 2018 Posted July 13, 2018 10 minutes ago, kclenden said: I liked your idea for using two decimal places for looks until I saw what the ISY does with far right zeros (hint - same thing it does with far left zeros). So the 10th, 20th or 30th of a month ends up as MM.D. Should still work correctly but not as pretty. I never see the resultant. I only use the value in prgrams and the format looks good there. :)
kclenden Posted July 13, 2018 Posted July 13, 2018 8 hours ago, larryllix said: I never see the resultant. I only use the value in prgrams and the format looks good there. :) But how do you get the value into the programs? When I enter "12.10", it puts "12.1" into the program.
gzahar Posted October 30, 2018 Posted October 30, 2018 On 1/26/2018 at 7:58 AM, larryllix said: Here is the program where I use the two decimal places just for looks. MM.DD The three time triggers are just insurance against a power loss or me playing with the program during the time. Note that the scratchpad variable can be Integer but the resultant variable MM.DD must be State in order to trigger the programs that depend on it. Also you need to set two decimal places for them. Set MM.DD - [ID 00B8][Parent 0006] If Time is 12:00:01AM Or Time is 3:00:01AM Or Time is 6:00:01AM Then $sISY.DayOfWeek = [Current Day of Week] $sISY.DayOfMonth = [Current Day of Month] $ISY_Date.scratchpad = [Current Day of Month] $ISY_Date.scratchpad /= 100 $ISY_Date.scratchpad += [Current Month (Jan=1, Feb=2, etc.)] $sISY.MM.DD = $ISY_Date.scratchpad Else - No Actions - (To add one, press 'Action') And this is how the usage looks. The programs do not care what day of the week or year it is. I have many programs for other devices that use the same variable for dates ranges independent of the year. Until V5 I was changing my program times every year but usually when the time comes it was forgotten about and had to be reset after the cycle should have started. Xmas Lights.9' tree - [ID 00BA][Parent 00C0] If ( Time is Sunset + 15 minutes And ( $sISY.MM.DD >= 11.15 Or $sISY.MM.DD <= 1.06 ) ) Or ( Time is 5:00:00AM And $sISY.MM.DD >= 12.24 And $sISY.MM.DD <= 12.26 ) Then Wait 1 second Set 'RecRm Christmas Tree' On Wait 6 hours Run Program 'Xmas Lights.9' tree' (Else Path) Else Wait 1 second Set 'RecRm Christmas Tree' Off Just noticed that my result for 29/100 is giving ..28. 28/100 = .28, 30/100 = .30, but 29/100 = .28 (unless I change the precision to 3 instead of 2, then it is .290 as expected). Running 5.0.13D. Anyone else seeing this? 1
apostolakisl Posted October 30, 2018 Posted October 30, 2018 19 minutes ago, gzahar said: Just noticed that my result for 29/100 is giving ..28. 28/100 = .28, 30/100 = .30, but 29/100 = .28 (unless I change the precision to 3 instead of 2, then it is .290 as expected). Running 5.0.13D. Anyone else seeing this? I remember something like that I encountered a while back and reported as a bug. Please report it as a bug where Michel will see it.
Jimbo.Automates Posted October 30, 2018 Posted October 30, 2018 Just noticed that my result for 29/100 is giving ..28. 28/100 = .28, 30/100 = .30, but 29/100 = .28 (unless I change the precision to 3 instead of 2, then it is .290 as expected). Running 5.0.13D. Anyone else seeing this? Yes I see the same, had to change the scratch variable to precision 3. Nice catch. I'm on 5.0.14.Sent from my Pixel 3 XL using Tapatalk 1
dbwarner5 Posted March 18, 2020 Posted March 18, 2020 On 5/5/2017 at 2:47 PM, bruceyeg said: ....... Having to constantly edit my programs to change the year is getting really annoying..... The way I handled this is when I am writing a program that needs to repeat every year, (like a birthday greeting to my wife from ISY..lol), I just put in a ORs with 5 years of dates. Its quick and easy to do when you are there writing the program as the JAVA script mimics each new line.. Yes, I still have to update it, but not for 5 years......cheers!
Recommended Posts