M1 w/ISY99 Programming Question

mikei-ma

Active Member
I'm using my ISY to program an output of my ELK to automate the Hot Water loop valve. I'm running into an issue when programming using on for XX time. It appears that the ELK/ISY is not respecting the most recent call and maintaining the first call. I have the loop turn on for 2 hours but am testing code for an "on demand" call to open the loop. The I'm testing is the same as the code below except I open it for 30 seconds, but it seems to want to keep it open for two hours even though I've sent another command to keep it open for 30 seconds. Do I have to specifically send a close (off)? Does the 'FOR' command not work when stacked?

On a side note.. how do I cut/paste code from the ISY that is 'human' readable.. the code below is exported but is in XML

Code:
<?xml version="1.0" ?><triggers><d2d><trigger><id>8</id><name>HW Loop</name><parent>1</parent><if><or /><schedule><daysofweek><mon /><tue /><wed /><thu /><fri /></daysofweek><at><time>18000</time></at></schedule><or /><schedule><daysofweek><sat /><sun /></daysofweek><at><time>28800</time></at></schedule><or /><schedule><at><time>59400</time></at></schedule><or /><schedule><at><time>73800</time></at></schedule></if><then><elk><cmd>122</cmd><output>8</output><p1>3600</p1></elk><elk><cmd>6</cmd><area>3</area><p1>3600</p1><p2>5</p2></elk></then><else></else><comment></comment></trigger></d2d></triggers>
 
Select the name of the program in the ISY and select Copy to Clipboard. Then paste that and well look at it...
 
I added the off command because it didn't seem to be working in my testing. But my question is about stacked FOR commands if I were to assign a button that when pressed ran Set Elk Output 'Output 008' On for 30 Seconds and it overlapped (the code below saying on for 2 hours) - who would prevail?

Code:
If
	    On Mon, Tue, Wed, Thu, Fri
	    Time is  5:00:00AM
	 Or On Sat, Sun
	    Time is  8:00:00AM
	 Or Time is  4:30:00PM
	 Or Time is  8:30:00PM

Then
	    Set Elk Output 'Output 008' On for 3600 Seconds
	    Set Elk Area 'Garage' Display Text on Keypads for 3600 Seconds, Content 'HW Loop'
	    Wait  2 hours
	    Set Elk Output 'Output 008' Off

Else
   - No Actions - (To add one, press 'Action')
 
As for viewing XML in human readable format, try getting Notepad++. It is capable of opening XML and doing a 'pretty-print' to make it readable.

http://notepad-plus-plus.org/
 
I added the off command because it didn't seem to be working in my testing. But my question is about stacked FOR commands if I were to assign a button that when pressed ran Set Elk Output 'Output 008' On for 30 Seconds and it overlapped (the code below saying on for 2 hours) - who would prevail?

Code:
If
	 On Mon, Tue, Wed, Thu, Fri
	 Time is 5:00:00AM
	 Or On Sat, Sun
	 Time is 8:00:00AM
	 Or Time is 4:30:00PM
	 Or Time is 8:30:00PM

Then
	 Set Elk Output 'Output 008' On for 3600 Seconds
	 Set Elk Area 'Garage' Display Text on Keypads for 3600 Seconds, Content 'HW Loop'
	 Wait 2 hours
	 Set Elk Output 'Output 008' Off

Else
- No Actions - (To add one, press 'Action')

The "for" command is an Elk feature. I do believe that even when you call for it in an ISY program, using the "for" command is telling Elk to run the output for that period of time and then Elk, on its own, shuts it down (ISY is not sending the off command).

In Elk rules, you have a check box asking whether you want an already running timer to restart. ISY does not ask you that question. Be experimentation, I have determined that ISY causes a timer to restart.

So, stacked "for" commands will expire after the amount of time indicated in the last "for" command sent.
 
Word of caution: The Elk is notorious for getting time incorrect for a week preceding or after daylight savings time. Thus I put event based programs in the Elk and time based events in the ISY. The only exception is program that automatically arm the Elk at various times of the day.
 
Back
Top