Jump to content

Why does this keep setting Night scene????


retsell

Recommended Posts

Posted

I am trying to create a simple away button on a KPL. The button is set to non-toggle mode with LED off. When you press the button I want it to check if it's daytime or night time and set the appropriate scene. Problem is, whenever it's sunset, it always sets the Away Night scene.

 

If

 

Control 'L-KPL C - Goodbye' is switched Off

 

And From Sunrise

 

To Sunset (same day)

 

 

 

Then

 

Set Scene 'Away Day' On

 

 

 

Else

 

Set Scene 'Away Night' On

Posted

Hello retsell,

 

The problem is:

You have a non-toggle mode and thus the Control will never ever change its state from Switched Off to anything else (after the first time you switch it off, the state will never ever change). Therefore, your condition amounts to evaluating whether or not it's day time.

 

What you might want to consider is to make this button toggle and use the the program to set its status (you have to put the button inside a scene as a responder) when it's day time.

 

With kind regards,

Michel

 

I am trying to create a simple away button on a KPL. The button is set to non-toggle mode with LED off. When you press the button I want it to check if it's daytime or night time and set the appropriate scene. Problem is, whenever it's sunset, it always sets the Away Night scene.

 

If

 

Control 'L-KPL C - Goodbye' is switched Off

 

And From Sunrise

 

To Sunset (same day)

 

 

 

Then

 

Set Scene 'Away Day' On

 

 

 

Else

 

Set Scene 'Away Night' On

Posted

You could also just use two programs:

 

If
       Control 'L-KPL C - Goodbye' is switched Off
   And From    Sunset
       To      Sunrise  (next day)

Then
       Set Scene 'Away Night' On

Else
       - No Actions -

 

If
       Control 'L-KPL C - Goodbye' is switched Off
   And From    Sunrise
       To      Sunset  (same day)

Then
       Set Scene 'Away Day' On

Else
       - No Actions -

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...