Jump to content

Please check programs. Fast on/off using Togglelinc Relay.


gtrotter4

Recommended Posts

Posted

Thank you to all the authors and contributors of all the detailed threads. I've spent MANY hours reading the forums, wiki's, and how to's and you'd think by now I'd be capable of writing any script I needed- HA! I wish. :roll:

 

I'm expanding my Insteon setup and need to learn ISY programming-- this is my first crack at writing programs. All of the state, body, condition programming is starting to make sense but I'm still very intimated. :shock:

 

Goal: Turn On/Off coffee maker using the fast On/Off ToggleLinc relay controlling my fluorescent under cabinet lighting. I also don't want to change the status of the under cabinet light. I want to avoid any programming mistakes to prevent future headaches and unwanted surprises.

 

Question: Are my 4 programs below the most efficient way to accomplish this? (they work but I don't think the light status is ideal) Do I need to create a state diagram with body's, condition's and all that jazz?

 

The programs below get the job done but I'm not confident they are good. Please chime in with your thoughts as I'd like to add a similar program in the Master Bedroom where the Fan Relay Togglelinc controls the Master Lamps.

 

First program: Coffee maker fast on.

If
       Control 'Kitchen / Under Cabinets' is switched Fast On
   And Control 'Kitchen / Under Cabinets' is not switched Fast Off

Then
       Set 'Kitchen / Coffee' On

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


 

Second program: Same as first program with cabinet light on.

If
      -(
      |     Control 'Kitchen / Under Cabinets' is switched Fast On
      | And Control 'Kitchen / Under Cabinets' is not switched Fast Off
      | And Status  'Kitchen / Under Cabinets' is Off
      -)

Then
       Set 'Kitchen / Coffee' On
       Set 'Kitchen / Under Cabinets' Off

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


 

Third program: Coffee maker fast off

If
       Control 'Kitchen / Under Cabinets' is switched Fast Off
   And Control 'Kitchen / Under Cabinets' is not switched Fast On

Then
       Set 'Kitchen / Coffee' Off

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


 

Fourth program: Same as third program with status light on

If
      -(
      |     Control 'Kitchen / Under Cabinets' is switched Fast Off
      | And Control 'Kitchen / Under Cabinets' is not switched Fast On
      | And Status  'Kitchen / Under Cabinets' is On
      -)

Then
       Set 'Kitchen / Coffee' Off
       Set 'Kitchen / Under Cabinets' On

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


Posted

The “not switched Off†or “ not switched On†part of the If statements are not needed. They drive the Else clause. Since there is nothing in the Else clause they are unnecessary.

 

The parens in the Fast Off Programs are not needed. With all the statements anded together the parens serve no purpose.

 

If

Control 'Kitchen / Under Cabinets' is switched Fast On

 

Then

Set 'Kitchen / Coffee' On

 

Else

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

 

 

If

Control 'Kitchen / Under Cabinets' is switched Fast On

And Status 'Kitchen / Under Cabinets' is Off

 

Then

Set 'Kitchen / Coffee' On

Set 'Kitchen / Under Cabinets' Off

 

Else

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

 

 

The “Set 'Kitchen / Coffee' On†in the following sequence is not needed. The coffee maker is turned On in the first Fast On Program.

 

Set 'Kitchen / Coffee' On

Set 'Kitchen / Under Cabinets' Off

 

I assume the Under Cabinets ToggleLinc load is controlling the actual lighting. These may flash On or Off as the Fast On and Fast Off will immediately affect the load which will then be overridden by the Programs.

 

If you are getting reliable Fast On/Fast Off with the ToggleLinc that is fine. Some folks have reported problems being able move the Toggle fast enough to consistently generate Fast On/Fast Off commands.

Posted
Goal: Turn On/Off coffee maker using the fast On/Off ToggleLinc relay controlling my fluorescent under cabinet lighting. I also don't want to change the status of the under cabinet light. I want to avoid any programming mistakes to prevent future headaches and unwanted surprises.

 

Question: Are my 4 programs below the most efficient way to accomplish this? (they work but I don't think the light status is ideal) Do I need to create a state diagram with body's, condition's and all that jazz?

Hello gtrotter4,

 

I am sure there are a number of different ways to accomplish what you want. I have one example as an alternative to having the cabinet lights turning on or off when switching the coffee on and off. One issue with it might be that turning the coffee on or off is no longer defined by Fast On turns the coffee on and Fast Off turns the coffee off. You will see what I mean:

 

Coffee On:

If
       (
            Control 'Kitchen / Under Cabinets' is switched Fast On
         Or Control 'Kitchen / Under Cabinets' is switched Fast Off
       )
   And Status  'Kitchen / Coffee' is Off

Then
       Set 'Kitchen / Coffee' On
       Set 'Kitchen / Coffee' (Beep Duration)

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

In this case if the cabinet light is On for instance and the coffee is off, press cabinet switch Fast On. If the cabinet light is off and the coffee is off then press the cabinet switch Fast Off. I added a single beep to the coffee device to confirm the coffee was turned on but the beep could be added to the cabinet switch instead. Note: The parens. is an “And†and the first “Control ‘Kitchen/Under…..†is an “Orâ€

 

To turn the coffee off a similar program is used:

 

Coffee Off:

If
       (
            Control 'Kitchen / Under Cabinets' is switched Fast On
         Or Control 'Kitchen / Under Cabinets' is switched Fast Off
       )
   And Status  'Kitchen / Coffee' is On

Then
       Set 'Kitchen / Coffee' Off
       Set 'Kitchen / Coffee' (Beep Duration)
       Set 'Kitchen / Coffee' (Beep Duration)

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

If the coffee is on and the cabinet lights are on then Fast On will turn the coffee off. Otherwise if the lights are off then a Fast Off will turn the coffee Off, followed by 2 beeps for confirmation.

 

Also note that if, say, the lights are on and the coffee is on and you want to turn both off then you could press Fast Off which will turn both off. Likewise if the lights are off and coffee is off and you wanted to turn both on then a Fast On would turn both On.

 

The only problem I can foresee would be if your comm. is not good, there is a possibility of the programs malfunctioning due to using the status of the device we are switching. I tested these two programs out for a couple of minutes and they worked fine for me.

 

Tim

Posted

Tim and Lee,

 

Just wanted to thank you for your responses.

 

I am very busy tonight but will definitely experiment with your suggestions when I have some more time.

 

Thanks again! Extremely helpful.

Guest
This topic is now closed to further replies.

×
×
  • Create New...