Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


  • 0

Disabled Scene Still Continues To Run??


puma

Question

Hi all

 

I have a scene written in LUA only my HC2 that even when disabled (turned off) it still continues to run. I have no idea why or how is there something in the code to make it ignore the on or off?

 

All the scene is meant to do is check if the window is shut and if so close the blind on the corresponding window 30 mins before sunset.

 

Thanks

 

Please login or register to see this code.

 

Edited by puma
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

On the scene configurations "general" tab, does the "run scene" option say manual or automatic?

Link to comment
Share on other sites

  • 0
  • Inquirer
  • When the scene is turned on it It is set to automatic, currently that I have it turned off it is set to manual.

     

    Edited by puma
    Link to comment
    Share on other sites

    • 0

    Ok, what I think is happening is that your scene is triggered manually whenever one of the parameters inside the brackets changes --[[..... ]]--

     

    This means your code runs whenever a window is opened/closed or it is 30 mins to sunset.

     

    So you could delete all the values statements without any impact (try it).

     

    To disable the scene:

    Disabling/enabling

    1. Open the Configuration Interface.
    2. Go to  > Scenes.
    3. Click Disable/Enable button next to the scene you want to disable/enable

    Alternatively, you could create a global variable called "SunsetClose" and set that to 1 in another master scene. This LUA code then checks if SunsetClose is 1 before closing your blinds.  This allows you to programmatically control whether the blinds close or not.

     

    Edited by Tim__
    Link to comment
    Share on other sites

    • 0
    10 hours ago, Tim__ said:

    Ok, what I think is happening is that your scene is triggered manually whenever one of the parameters inside the brackets changes --[[..... ]]--

     

    This means your code runs whenever a window is opened/closed or it is 30 mins to sunset.

     

    So you could delete all the values statements without any impact (try it).

     

    To disable the scene:

    Disabling/enabling

    1. Open the Configuration Interface.
    2. Go to  > Scenes.
    3. Click Disable/Enable button next to the scene you want to disable/enable

    Alternatively, you could create a global variable called "SunsetClose" and set that to 1 in another master scene. This LUA code then checks if SunsetClose is 1 before closing your blinds.  This allows you to programmatically control whether the blinds close or not.

     

     

    Yes, you are using my timer scene and it doesn't seem to care of scene is disabled before calling the scene.

    Unfortunately I don't have the HC2 anymore so I'm reluctant to patch the Timer scene.

    However, you can put a test in your code.

     

    Please login or register to see this code.

    and it will exit if the scene is disabled.

    • Like 1
    Link to comment
    Share on other sites

    Join the conversation

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

    Guest
    Answer this question...

    ×   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...