Jump to content

Glitch with AWAY


aLf

Recommended Posts

Posted

I have a KPL button which is linked to an ApplianceLinc. OFF on each shows ISY that the house is empty. IN turn there is a folder which shows true when I'm AWAY (IF KPL & APL are OFF). Simple. I have a program which runs an "ALL OFF" command every hour to each Insteon SW. Also simple. The "ALL OFF" program is tagged as "Run at Startup". Everything works good until a power outage. I had one the other day. When the power (and ISY) came back up, of course the "ALL OFF" began to run , but the KPL button came back in the "ON" posistion rather than the "OFF" as it was before the outage. This in turn left the AWAY folder as false.

 

Is there some way to to get a folder tag (in this case be AWAY & TRUE) after the power comes up? I 'm thinking that the AWAY folder running at startup would be better than the "ALL OFF", maybe they both should be? I'd like to see the KPL & APL go AWAY and the AWAY folder become TRUE after reboot. Any help is appreciated.

 

aLf

Posted

If you want a couple of devices to be guaranteed off after power failures, could you not create a simple program to run at startup which simply states:

 

Then
set KPL off
Set APL off

 

Another possibility would be to send yourself a notification in the event of power failure, allowing you to remotely confirm or cnage your "away" status. This way, you can choose whether you want to be home or away whenever this happens, rather than just assume an "away" status.

 

I was under the impression (confirmed by my experience) that insteon devices reverted to the status held before power failures. I am a little surprised yours are not. However, I don't much rely on this feature, so it is possible that mine don't and I have just failed to notice (power failures are pretty uncommon at my house.)

Posted

On the Configuration page if Catch Up Schedules at Restart is checked the ISY will run all timed programs since last midnight. That's the way I read it. So if you have any programs set to run based on time they will be run and possibly turning something on.

Posted

So is there a way to run a program when the power goes out and back on? If there is a way to have ISY know that, it would be simple to just have a program that would turn the "AWAY" scene (KPL & APL) off and have it run at startup. Would I just make program that is like this:

 

Program: AWAY Backup

If

- No Conditions - (To add one, press 'Schedule' or 'Condition')

 

Then

Set Scene 'AWAY' On

 

Else

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

 

Then just mark it as run at startup...

 

Thanks,

 

aLf

 

Also, how do you have ISY email you after a reboot, i.e. power outage?

Posted

aLF,

 

So is there a way to run a program when the power goes out and back on?

Yes, set the program to “Run at Startupâ€

 

 

If there is a way to have ISY know that, it would be simple to just have a program that would turn the "AWAY" scene (KPL & APL) off and have it run at startup. Would I just make program that is like this:

 

Program: AWAY Backup

If

- No Conditions - (To add one, press 'Schedule' or 'Condition')

 

Then

Set Scene 'AWAY' On

 

Else

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

 

Then just mark it as run at startup...

Yes except, if I followed your original post correctly, you would want to turn the away scene "off" at start up (in your example above).

The only problem is if you were home and the power cycled off-on the ISY would still turn the scene Away off even though you are home.

 

 

If you want the ISY to remember the state of your Away program and scene after a reboot I would suggest the following:

 

Program: Reboot Away KPL Status

If
       Status  'KPL Button' is not On
    Or Status  'APL ' is not On

Then
       Set Program 'Reboot Away KPL Off Set' To Run At Startup
       Set Program 'Reboot Away KPL On Set' To Not Run At Startup

Else
       Set Program 'Reboot Away KPL On Set' To Run At Startup
       Set Program 'Reboot Away KPL Off Set' To Not Run At Startup

Program: Reboot Away KPL Off Set

If
  - No Conditions - (To add one, press 'Schedule' or 'Condition')

Then
       Set Scene 'KPL Button and APL' Off

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

Program: Reboot Away KPL On Set

If
  - No Conditions - (To add one, press 'Schedule' or 'Condition')

Then
       Set Scene 'KPL Button and APL' On

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

I use these programs for my own Away programs, only I turn "On" the KPL buttons to indicate I am Away, and turn them "Off" when I am home. So I had to reverse the logic in these examples (hope I got them correct).

 

 

 

Also, how do you have ISY email you after a reboot, i.e. power outage?

Program: Reboot Email

If
  - No Conditions - (To add one, press 'Schedule' or 'Condition')

Then
       Set Program 'Reboot Email' To Run At Startup
       Wait  15 seconds
       Send Notification to 'Tim'
       Wait  1 minute 
       Run Program 'Reboot Email' (Else Path)

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

This is the program I use to send notification of a reboot. Remember to initially set this program to "run at reboot."

 

Tim

Posted
Also, how do you have ISY email you after a reboot, i.e. power outage?

 

One must first set up a notification under tabs: configuration/email/notifications

 

The second step is to create a program that sends the notification based on desired conditions.

Posted

Why not use variables to indicate a reboot took place and your AWAY status?

 

I have a program that runs at boot time and test if a variable is 0, which it will be at boot time because the init value is 0. I increment the variable and then wait 2 minutes before sending a notification. And by doing this the program can have a normal status of enabled.

 

Why the 2 minute wait you may ask?

 

There are a couple of reasons.

 

1) Many times when I have power failures, the power does not just go off, but basically does long blinks. That is the power will go off for a few second and then come back on for a few seconds or more and then go off again, sometimes for a few minutes and then come back on. Most of the time this is because a tree has fallen on a power line some where.

 

2) When power is lost and comes back it takes a minute or more for the cable modem and router to do their self test and the cable modem to get its IP Address and network connectivity to be established.

 

Then I have another variable that I take the current value and make it the init value. This keeps up with how many times the ISY has rebooted.

 

So the point to all this is your AWAY status could be in a variable and each time an event happens that would change it, then set the value as the init value. Then if you have a power failure, the init value will be what the status was before the power failure.

 

There is a small window where things could get out of sync. That would be that a power failure took place just as you got home and you walk in and press the button while the ISY is rebooting. But how often would that happen?

Posted

jca001,

 

I am old school with programs and haven’t done much with variables. As such I have been trying to figure out a program using variables to accomplish the same results as the 3 program examples above (Reboot Away KPL Off, Reboot Away KPL On and Reboot Away KPL Status). It seems to me, at least as far as I can see, it would still require 3 programs + variable. But I do not have the experience with variables as some of you do.

 

I know it would be asking a lot but could you provide example programs and variables to demonstrate how you would replace the 3 programs mentioned?

 

Thanks,

Tim

Posted

TJF1960,

 

Here is my program that runs when ISY-99 boots.

 

If

$Int_SBC_Status is 0

 

Then

Wait 2 minutes

Send Notification to 'Home and Work' content 'System Boot Check'

Wait 2 seconds

Send Notification to 'Cell Phone' content 'System Boot Check'

Wait 2 seconds

$Int_SBC_Count += 1

$Int_SBC_Count Init To $Int_SBC_Count

$Int_SBC_Status = 1

 

Else

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

 

 

The program is set to run at boot up and the init value for $Int_SBC_Status is 0. As you can see it increments $Int_SBC_Count by 1 and then sets the init value to the new value. This lets me know how many time the ISY-99 has rebooted in case I miss the emails.

 

Now as far as an AWAY program I will not attempt to write it because I am not sure what you use to trigger it and what all it does when it is triggered. I assume you press a key and when it is on indicates you are away. This would be when you would set a variable to 1 and also set the init value to 1. When it is pressed again to turn it off set the variable to 0 and the init value to 0.

 

Then all the programs that check the true/false of a program you are using as a status would now check the value of the variable instead. As an example if you had a program that the if tested if there was motion and the away program was true would be changed to if there is motion and the variable is greater than 0.

 

Depending on how some of your programs do there if test, you may need to use the state variables instead of the int variables so when the variables change they will cause your programs to reevaluate the if.

Posted

Jack:

 

As Frank Sinatra said " you had me, then you lost me"!

 

I have absolutely no idea how to do this (variable) thing. I thought I understood ISY until this. I'd love to know how many times my ISY re-boots, but I have no clue where to begin with your model. If there is a "Variables for Dummies" sign me up and send the the textbook link.

 

aLf

Posted

The Variable Init value is what the variable is set to when ISY boots. The Program is setting the Init value to a number that is bumped each time the ISY boots. The effect is to have an incrementing Variable Init value which reflects the ISY boot count.

Posted

aLf:

 

LeeG is correct.

 

The code I posted is not just a model it is what I use. You could used most of it as is, just change or remove the notifications. Before you try to write the program define the variables and their init value as 0. Both variables are INT and not STATUS variables.

Guest
This topic is now closed to further replies.

  • Recently Browsing

    • No registered users viewing this page.
  • Who's Online (See full list)

  • Forum Statistics

    • Total Topics
      37k
    • Total Posts
      371.4k
×
×
  • Create New...