
dnl
Members-
Posts
75 -
Joined
-
Last visited
Everything posted by dnl
-
Larryllix summed it pretty well. There is a link near the bottom of the first post. Follow that link to a thread that discusses using variables in the programming structure.
-
Hi Michel, Today I upgraded my local ISY99 to 3.1.17 without any difficulties but left my remote ISY99 running 2.8.16 -- didn't want to take a chance the upgrade might crash and I would have no way to recover remotely. So the two ISY are now running different versions. When I launch two browser windows to access the two systems concurrently, the first one I access appears to be OK. The second one I access appears OK in most respects. The areas I noticed that are not OK are (1) Help:About is blank and (2) program details shows only condition statements; statements in the THEN or ELSE clauses and comments are not shown. I expect this is caused by the wrong version of Java applets being in the cache for the second accessed system. If I close all browser windows and then launch the browser to access either one of the systems, everything appears to be OK. Can I assume everything is really OK or should I clear the cache every time I switch systems?
-
Agreed the complexity is greater but I can see some ways where this technique might be used to advantage. 1) The delay time can be the result of a calculation. The ability to do calculations right now is limited but not non-existant. 2) The delay code can be packaged as a subroutine and called from multiple places, reducing program maintenance. Of course, it may be necessary to take care not to call the routine again before it completes. 3) I don't know whether a variable can be set directly from a REST call but I believe it is possible to do it indirectly by controlling which programs execute and having those programs set a variable as desired. There may not be many instances where we need or want to do any of these things but if we do, some approach like what ergodic suggests is needed.
-
The advantage is that the delay time is programmable. Some day I am sure UDI will support the use of variables in a wait statement but until then something else is needed.
-
Hi ergodic, I think your example code could use the ELSE clause to achieve some synchronization. Execution of the following code would be initiated by setting $F = 0. What do you think? //___________________ //Program TestVarWait If $F = 0 Then $V = 30 Run Program 'Wait.V' (If) Else Run Program 'DoItNow' (If) //______________ //Program Wait.V If $V > 0 Then Wait 2 seconds $V -= 2 Run Program 'Wait.V' (If) Else $F = 1
-
Thanks Illusion. Right you are. Actually, there was more than one instance of "KPL A" in the first example and I updated the post to correct them.
-
I also look forward to having extended capabilities for using variables. I have an approach that controls repetition and wait times with variables. I admit it is a kludge but I think it is better than nothing. For repetition: (1) set a variable (REPLIMIT) to contain the number of repetitions you want (2) code the repeat loop in your program to repeat 999 times (or some number larger than you will ever want) (3) initialize another variable (REPCOUNT) to zero just before the repeat loop and increment it by one inside the repeat loop (3) run the IF clause of another program (REPCONTROL) inside the repeat loop (4) the IF clause in REPCONTROL compares REPCOUNT against REPLIMIT; when REPCOUNT > REPLIMIT, the THEN clause stops execution of the first program. This approach requires each pass through the repeat loop to run longer than it takes to run the other program so a short WAIT statement may be needed after the RUN command. Alternatively, you could make REPCOUNT a state variable and omit the RUN statement in the loop. Each increment of the variable would invoke the REPCONTROL program. For wait: This is a similar technique ... (a) using one variable (WAITLIMIT) to contain the length of the wait that you want, ( a repeat loop in your program to repeat some very large number or times © using another variable (WAITCOUNT) to count loops (d) running the IF clause of another program (WAITCONTROL) inside the repeat loop (e) putting a WAIT statement inside the repeat loop. I have not tried this but I suspect it will not be possible to achieve precise control for some small number of seconds but it should work fine for larger increments such as multiples of two- or three-second intervals.
-
Edited to remove a duplicate post.
-
Hi Lee and Michel, Sorry for the slow response -- busy weekend. You have diagnosed the situation perfectly. I mistakenly added them as 2475S. Mystery solved. Thank you so much for your help.
-
As an educational exercise, I was wondering if an ILL could be converted from responder to controller by ... 1. linking the ILL to another device outside the ISY 2. using ISY diagnostics to save the ILL table to a file 2. editing the saved XML file to change the title 4. running a comparison 5. loading the edited file into the ISY table Does the load function in the compare dialog box update the ISY table for the device or is just for diagnostic comparisons?
-
Help about shows ver 2.8.16. I did clear the cache and all UDI certificates. I followed Michel's instructions in the 2.8.16 post exactly. The device link table shows only one A200 entry for the PLM. I added the ILL by specifying address and device type, electing to clear all links. EDIT: Lee, I removed the device and added it again letting the ISY discover the type of device. It was added as a controller -- and as you indicated, status is now updated. I wish there was a way to convert all the other ILL I have to controllers without having to remove and add. 2ND EDIT: Lee, I forgot the most important part. Thank you very much for the help.
-
Hi LeeG, Thanks for the reply. I upgraded to 2.8.16, removed one of the ILL and added it again but it is still only a responder. I guess this is a new feature of 3.1.x? What is worse is that the ILL status is not updated unless I query it. This does not seem right.
-
Today for the first time I realized that all of my In-LineLinc modules appear in blue, meaning they are only responders. The ILL can control other devices so I would have expected it could also be a controller. I also noticed that the status of the ILL does not update automatically. I can query it to get proper status. My ISY is at ver 2.8.10. Is this normal or what?
-
Hi vbphil. I have been thinking about updating this post to cover the very thing you mentioned. The introduction of IF conditions using non-state variables allows for conditional logic that is not affected by changes in state. There are also a few optimizations that could be added. Maybe after taxes are done ...
-
Hi robin, I thought I would jump in to clarify one point and venture a guess about why your single program did not work as expected. An IF condition is not re-evaluated at the end of a WAIT. The IF condition is subject to re-evaluation at any time during a WAIT. All program statements run without interruption with two exceptions: WAIT and REPEAT. If you have a program with any kind of statements except WAIT or REPEAT, that program will run to completion (unless power fails during the few milliseconds or possibly seconds while it is running). If any event affects any of its IF conditions during execution, the program will run to completion and the IF condition will be evaluated for that program only after its completion. When a WAIT statement is executed, the program can be interrupted immediately if an event affects any of its IF conditions. The same is true for a REPEAT; the program can be interrupted at the bottom of a REPEAT loop. This subject has been discussed at great length on this forum. Except for the recently announced global variables that are not declared state variables, all IF conditions serve two functions. One - they control whether the THEN clause or the ELSE clause is executed. Two - they control when the IF clause is evaluated. Whenever an event affects a condition, the IF clause is evaluated and the program will execute accordingly (I am assuming the program is not disabled). As mentioned above, the next execution will not occur until after any current execution completes, or a WAIT or REPEAT is executed. If a particular condition affects the logic of a program AND you want to avoid having an associated event interrupt the execution of a program with a WAIT statement, then you must separate the code into two programs. One program has an IF clause that runs another program and the other program has code with the WAIT statement but an empty IF clause. I hope this makes sense. If you are familiar with programming, the ISY may fool you at first. Its programming model is not typical. Now for the speculation. You mentioned that your single program status changed to False after 5 minutes. I believe the only way that could have happened is that either there is a condition in its IF clause or some other program executed the else clause of the program. I hope this helps.
-
Good advice. The MS just quit working again so it's time for a call to SmartHome. Thanks your your comments.
-
It is version 2 with jumper 5 set for configuration by software.
-
Thanks for the reply. The voltage is above 8.4 V when in linking mode while reading the device table. I looked at the log file again. The log records look normal up to Friday morning, Mar 25. Then the log looks something like this (DD=dawn/dusk; MS=motion): MS multi Fri, Mar 25, multiple (looks normal) DD 0% Fri, Mar 25, 9:27 AM MS 100% Fri, Mar 25, 9:31 AM MS 0% Sat, Mar 26, 11:59 PM MS multi Sun, Mar 27, multiple (looks normal) DD 0% Sun, Mar 27, 8:47 AM MS multi Sun, Mar 27, multiple (looks normal) DD 100% Sun, Mar 27, 7:20 PM MS multi Sun, Mar 27, multiple (looks normal) MS 0% Sun, Mar 27, 7:17 PM MS 0% Tue, Mar 29, 6:24 PM DD 100% Tue, Mar 29, 6:52 PM DD 0% Wed, Mar 30, 7:51 AM DD 100% Wed, Mar 30, 5:58 PM DD 0% Thu, Mar 31, 8:34 AM MS 100% Thu, Mar 31, 6:35 PM <-- reset by pressing set button all appears normal It appears both MS and DD stopped working Friday morning, Mar 25 until the one MS entry at midnight Sat, Mar 26. Both appear to start working on Sunday morning, Mar 27. Then stop working Sunday evening until Tuesday night. Only DD on Wednesday and Thursday AM, Mar 30-31. Only motion Thurs night. Nothing more until Friday when I reset the device. Marginal RF communication? Maybe but the MS and WAP are about 25 feet apart with clear line of sight between them. In any case, the problem was solved by pressing the MS set button. Nothing else was changed. I would appreciate any thoughts about what might have caused this.
-
Hi LeeG, You mentioned a low battery. Do you think I may have a low battery because the MS stopped working or because of something I wrote? If it is from something I wrote, then I should clarify I had no reason to suspect a low battery. The MS is working OK now. I checked the battery's voltage while in the MS and it is a little higher than 8.5V. I seem to recall someone on the forum did some testing and concluded the MS can work on voltages below 8V. Do you have a different experience or has there been some misunderstanding about whether I have low battery?
-
Hi LeeG, Thanks for the reply. The ISY did reboot because of loss of power. I rewired the closet where the ISY is kept so both ISY and the PLM had power down/up cycles. The wireless access point that the MS talks to did not cycle. After the reboot I noticed the MS status was blank and I was not concerned at first but I did become concerned later when subsequent motion did not trigger an ON status. There was no motion for almost an hour (much more than the countdown period) and subsequent motion did not cause the ISY to see an ON status. I looked into the log and discovered there had been no motion sensor status messages for at least a day prior to my rewiring. I went to the MS, pulled it down and noticed the LED was not blinking with any motion. I pressed the set button, the ISY reported ON and the MS LED blinked as normal. As best I can tell, the MS stopped working yesterday but I did not notice it until today after the reboot. The low-battery indicator is OFF, meaning the battery is OK. I never tried this before but queried the battery-low indicator from the ISY (while the MS was otherwise inoperatvie) and the ISY appeared to receive a status update. (I was surprised that the query worked because I would not expect any query would work while the MS is asleep.) In any case, the successful query explains why I had battery-low status but not motion or dawn/dusk status. To sum up, I do not think the reboot caused any problem with the MS. I think it only helped me discover the problem. So I wonder if anyone else has had a MS stop working and, if so, do they know how to recover from it other than pressing the set button. Also, in those rare cases where status is blank, is there a way to detect this condition? It appears there is no way for a program to distinguish between blank status and OFF status.
-
Yesterday my ISY stopped receiving status reports from a 2420 motion sensor. Displays of both motion and dawn/dusk status were blank. Low battery indicator showed as OFF. I pressed the setup button in the MS and immediately the ISY showed motion status. A few hours later there was an update of dawn/dusk status. Has anyone had similar problems? Any way to recover without retrieving the MS to press the set button? All ISY programs that checked for MS status executed as if MS status was OFF. Is there any way to detect when status is blank (undefined) rather than ON or OFF?
-
Hi Michel, I did some testing today with custom notifications but could not recreate the problem. You should probably disregard my report unless it happens again. I have one other thought. I did have a few other problems until I deleted all of the UDI Java certificates. I had thought I did not need to delete them since I was upgrading from 2.7.15. After deleting those certificates, the other problems disappeared. I believe I had problems with custom notifications both before and after deleting the certificates but I am not certain. If this could explain the problem, then I believe that probably is what happened.
-
Hi Michel, Today I updated from 2.7.15 to 2.8.16. Everything went smoothly but I noticed two changes in behavior. The first change concerns email notifications. I use a server that requires authentication, which I know you do not support. I was able to get things working with the help from others on the forum by using port 587 and with TLS checked. After the upgrade to 2.8.16, email notifications no longer worked. (It may be helpful to also point out that the "Test" button did send test messages but the Notify commands in programs did not work.) I tried unchecking TLS and notifications began working again. This is not a problem now but I thought I should report it because it is a change. The second may not be a change but it is a problem I had not noticed before. I have used customized notifications on another ISY running 2.8.10. With the upgrade on this ISY, I began setting up customized notifications. Sometimes changes would not be saved. At first I thought I might have clicked on "Cancel" by mistake or not clicked on "Save" but I took extra care to ensure I did click on the right buttons. There are changes I made that were lost. This problem occurred several times but it does not occur all the time. I have not noticed any other problem.
-
Hi Illusion, I offer these ideas for things to try so that you might discover what is unusual to your situation. You mentioned this switch is a 2476D. You could try a different model of switch, especially one that does not have a dimmer. I do not know what type of load you have. You could try a different type of load (especially if you eliminate the dimmer) or at least you could swap out the lights you have been using. It seems unlikely the load could cause this problem but the problem itself is unlikely. Any chance you could try a different PLM? Didn't this problem start after you changed PLM? These thoughts may not be very helpful. Maybe they will give rise to better ideas.
-
Hi Illusion, Have you tried keeping the switch connected to a light but not adding it to the ISY? or having a friend without a ISY wire it into his house? This might confirm the switch is doing this on its own and is not being acted on by something else.