Jump to content

Wheres Waldo...Who can stop my error???


snownh2o2

Recommended Posts

Posted

Hi guys, and gals,

 

I am beating my head off the wall. I think it is one of those simple mistakes but I cant located it, so may someone can catch it for me.

 

Every morning my ISY is stuck in a loop...I thought I had it fixed but this morning it happened again. Also every morning the following 2 programs are running when the should not be since I am at home and the state variable for home is active (1):

 

As I re-examine the programs, I am thinking that maybe in the A:Audio and A:Lights program folders it is possible that the "And Folder 'H:Home' is False" should be remove for timing issues.....I really don't know though because I don't recall modifying these programs in a while and they used to work just fine.

 

Also is it possible that a Disabled program can be still causing a loop? I wrote some new time of day programs that aren't finished yet, but keep them disabled. They do appear in the isy program summary and I am wondering if they can jam up the isy since the old programs used to run fine. When the looping issue is in effect I can not log into the isy without an unplugging of the isy and then immediately logging in to the console and disabling flagging programs. The loop seen in the event viewer level 3, shows time stamps over and over. Its not the isy going out to check the time server.

 

 

 

My file structure is as follows:

 

 

 

The programs read as follows starting with the flags that activate them:

 

-------Flag - Away_BRZ^FR:4KPLD:H.A.V-------

If

Program 'Wifi Status - AWAY' is True

Or Control 'House / 1st FLR / Breezeway / BRZ 4KPLDg_Away.Home.Vac' is switched On

Or Control 'House / 1st FLR / Breezeway / BRZ 4KPLDh_Away.Home.Vac' is switched On

Or Control 'House / 1st FLR / Family Room / FR 4KPLDg_Away.Home.Vac' is switched On

Or Control 'House / 1st FLR / Family Room / FR 4KPLDh_Away.Home.Vac' is switched On

Then

Run Program 'Flag - Home_BRZ^FR:4KPLD:H.A.V' (Else Path)

Else

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

 

 

-------Flag - Home_BRZ^FR:4KPLD:H.A.V-------

If

Program 'Wifi Status - HOME' is True

Or Control 'House / 1st FLR / Breezeway / BRZ 4KPLDg_Away.Home.Vac' is switched Off

Or Control 'House / 1st FLR / Breezeway / BRZ 4KPLDh_Away.Home.Vac' is switched Off

Or Control 'House / 1st FLR / Family Room / FR 4KPLDg_Away.Home.Vac' is switched Off

Or Control 'House / 1st FLR / Family Room / FR 4KPLDh_Away.Home.Vac' is switched Off

Then

Run Program 'Flag - Away_BRZ^FR:4KPLD:H.A.V' (Else Path)

Else

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

 

 

-------Folder Conditions for 'A:Away'-------

Add conditions to limit when programs in this folder are allowed to run.

If

Program 'Flag - Away_BRZ^FR:4KPLD:H.A.V' is True

And Program 'Flag - Home_BRZ^FR:4KPLD:H.A.V' is False

Then

Allow the programs in this folder to run.

 

 

-------Folder Conditions for 'A:Audio'-------

Add conditions to limit when programs in this folder are allowed to run.

If

Folder 'A:Away' is True

And Folder 'H:Home' is False

Then

Allow the programs in this folder to run.

 

 

-------PROGRAM:A:Russound Off-------

If

Folder 'A:Audio' is True

Then

Wait 10 minutes

Resource 'Russound_RIO_MCA-C5_All_Zones_OFF'

Wait 10 seconds

Run Program 'A:Russound Off' (Else Path)

Else

Run Program 'A:Russound Off' (Else Path)

 

 

-------Folder Conditions for 'A:Lights'-------

Add conditions to limit when programs in this folder are allowed to run.

If

Folder 'A:Away' is True

And Folder 'H:Home' is False

Then

Allow the programs in this folder to run.

 

 

 

-------PROGRAM:A:All Lts OFF

If

Folder 'A:Lights' is True

And From Sunrise + 30 minutes and 1 second

To Sunset - 30 minutes (same day)

Then

Wait 10 minutes

Set Scene 'Scenes / Scn: multiple Areas / Scn_Away' Off

Wait 10 minutes

Run Program 'A:All Lts OFF' (Else Path)

Else

Run Program 'A:All Lts OFF' (Else Path)

 

*******These are the WiFi Programs that help control the Home and Away Flags

 

-------PROGRAM/FLAG:Wifi Status - AWAY-------

If

$WiFi_MAC_Registration_HTC_Inspire_4G is 0

Then

Run Program 'Wifi Status - HOME' (Else Path)

Set Scene 'Scenes / Scn:Buttons / Buttons - Away' On

Else

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

 

 

-------PROGRAM/FLAG:Wifi Status - HOME-------

If

$WiFi_MAC_Registration_HTC_Inspire_4G is 1

Then

Run Program 'Wifi Status - AWAY' (Else Path)

Set Scene 'Scenes / Scn:Buttons / Buttons - Away' Off

Else

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

post-1311-14047416455_thumb.png

post-1311-140474164551_thumb.png

post-1311-140474164554_thumb.png

Posted

I haven't taken a lot of time to digest what your programs are doing yet but...

 

You have several programs with recursive loops that could eat up your ISY CPU time and at first glance I don't see any other useful function. Here's one of them.

 

Program 'A:Russound Off'

----------------------------

Else

- Run Program 'A:Russound Off' (Else Path)

Posted

Would it be best to leave the ELSE line blank or to put a stop command in. I had written it that way in case the program was running the THEN sequence and the house switched back into HOME mode before it finished. Thinking that it would stop the AWAY program from finishing.

 

An example being: the radio was on and I accidently clicked the Away button, setting the radio to turn off in 10 minutes. However since the button press was an accident I would press the button again to go back to Home settings. I was trying to have the radio not shut off in the 10 minutes with an issue as such.

 

Thanks for the help,

Matt

Posted
Would it be best to leave the ELSE line blank or to put a stop command in. I had written it that way in case the program was running the THEN sequence and the house switched back into HOME mode before it finished. Thinking that it would stop the AWAY program from finishing.

 

An example being: the radio was on and I accidently clicked the Away button, setting the radio to turn off in 10 minutes. However since the button press was an accident I would press the button again to go back to Home settings. I was trying to have the radio not shut off in the 10 minutes with an issue as such.

 

Thanks for the help,

Matt

I don't want to mess you up as I really don't do my programs that way and don't understand some of your style. I have to assume you do not have variables in your version.

 

Anyway, I just see some recursive loops in you else statements calling themselves without any function I can see. Once you call the else part of the program it should test as false without needing to loop on it. A few tight recursive loops running like that should probably lock up the ISY CPU so that all other functions grind to a halt. I would just leave them blank and try it.

Posted

The only variable I use in this section is a state variable for MAC address status via WiFi to obtain HOME and AWAY status

 

I will do a quick backup and pull the ELSE statements.

 

Thanks,

Matt

Posted

I have to agree with Larry on this. While I also did not spent enough time to fully understand what you are attempting to accomplish here, I do see several programs that will loop due to the else statements.

 

Program 'A:Russound Off'

Program 'A:All Lts OFF'

 

Are both going to cause endless loop problems as written.

 

-Xathros

Posted

Quick interjection question:

Do program state changes cause triggers in conditions testing their state dynamically (like a state variable)?

Posted

Yes.

 

-Xathros

Guest
This topic is now closed to further replies.

  • Recently Browsing

    • No registered users viewing this page.
  • Forum Statistics

    • Total Topics
      37.2k
    • Total Posts
      372.4k
×
×
  • Create New...