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

Lights off when lux is above XX


kevin

Question

Hi,

 

I have created a scene that turns off the lights when the lux level is above 40. But the scene only starts when there is a change in lux level. So when the lights are on and the lux level is already above 40 then the lights stay on until it, for example, changes from 80 to 60 or 80 to 200. That will trigger the scene.

 

How can I achieve that the lights also turn off when the lux is already above 40 without a change in lux level?

Link to comment
Share on other sites

8 answers to this question

Recommended Posts

  • 0

...that's, why i have no script at all in HC2 triggered by header... only looping.

sorry for offtopic. so about your qeustion you can add in header %autostart%

and check manually condition.

so when HC2 started or when you re-save scene - scene will running - check conditionla manually. it's easy

Edited by 10der
Link to comment
Share on other sites

  • 0

I use these two scenes to control my window lights during the day. (Slightly shortened)

-- Scene No. 1 - Is it Light or Dark
------------------------------------

Please login or register to see this code.

 

-- Scene No. 2 - On or Off
--------------------------

Please login or register to see this code.

 

Edited by RH_Dreambox
Link to comment
Share on other sites

  • 0
  • Inquirer
  • @RH_Dreambox

     

    Thank you for these scenes, they look useful for me. My only question is, what does that math.random with different values do?

     

     

    Link to comment
    Share on other sites

    • 0

    Random delay 

    may be for fun effect no mote as for me just for fun ;) 

    Link to comment
    Share on other sites

    • 0

    @kevin

    If you turn the lights on and off randomly, it looks more like someone is home even if the house is empty. That's why :-)

    Edited by RH_Dreambox
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Finally had the time to add this to my HC, unfortunately I get an error in scene 1 on the debug line. I can't see why but this is the error

     

     

    [DEBUG] 22:57:47: 2020-08-14 22:57:47.164521 [ fatal] Unknown exception: /opt/fibaro/scenes/314.lua:47: attempt to concatenate a nil value
     

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Yes I have. But it is already solved by a recreating the variable. Don’t know what was wrong with it because the error was only on the debug line.

     

    other question, do you have a working scene that lights turn off when XX minutes  no motion is detected.

     

    the one I have now doesn’t work great. It starts counting on the first motion but doesn’t start recouting when a new motion is detected.

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