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

Scene graphic blocks run for x s.


Question

Posted

Hello, I'm trying to create a scene that if motion sensor detects movement and the light is OFF, then it turn the light on for 60s. But I have to turn ON and add another line to turn it OFF after 60s, is this the better way to do this?

 

Please login or register to see this attachment.

 

Thanks.

9 answers to this question

Recommended Posts

  • 0
Posted

Im using separate scene to turn off the lights as in your case they will not switch off is switched on mamualy or not from this scene....

  • 0
  • Inquirer
  • Posted

    You are right, they don't turn OFF even if I press the button :/

     

    So you are saying that I need to create this scene:

    Please login or register to see this attachment.

     

    And this one:

    Please login or register to see this attachment.

     

    This works great, but if I want to turn the light ON and stay that way, as the movement detector sees me before I push the button ( button is my momentary switch), after 60s the light turn OFF even if I push the button to turn ON/OFF in that 60s.

     

    The only way to do this, is to turn on the light in my HC2, or if I stay put near a button and press it after it turns OFF (60s) the lights stays ON as I want.

     

    So how can I manage to do this?

     

    Thanks.

     

    • 0
    Posted

    Ive added one variable as the condition, which I triggrr manually when exceptionaly dont want auto on/off

    • 0
  • Inquirer
  • Posted

    Can you grab me a screenshot please?

    • 0
    Posted

    How to attach a screenshot here ? No clue

    Please login or register to see this image.

    /emoticons/default_sad.png" alt=":(" srcset="https://forum.fibaro.com/uploads/emoticons/[email protected] 2x" width="20" height="20" />

     

    But simply add variable as the condition to turn on in the scene and change this variable either manually by scene or automatically by switching of a different device ( if Lamp XZ is on, then change variable to Manual, therefore teh automatic switch on or off will not be executed in the first scene )

    • 0
  • Inquirer
  • Posted

    When you start typing your reply, in the bottom right corner you have the button 'More Reply Options', click on it.

     

    Then in the bottom of the text box is a Attachment box so you can attach your screenshots. Please

    • 0
    Posted

    When you start typing your reply, in the bottom right corner you have the button 'More Reply Options', click on it.

     

    Then in the bottom of the text box is a Attachment box so you can attach your screenshots. Please

    Please login or register to see this attachment.

    • 0
    Posted

    A bit more complex, but the variable "Auto" I use to auto or manual ON/OFF

    • 0
  • Inquirer
  • Posted

    I need somebody to help my writing this scene, I'm not going there with blocks I think, maybe I need Lua :/

     

    Let me explain it:

     

    - I want to turn on the Light A when Motion 1 detects movement and turn it off after 60s.

    - In this period of time (60s) If Motion 1 detects movement ignores it.

    - But if I need more that 60s I want to touch the wall button and If Light A state is changed it will turn off the Light A, but I want to turn it back on and stops the 60s timer, but I can't manage do do this.

     

    I thought the installation of the hardware was the hardest part... I was completely wrong. :/

     

    One of my difficulties is to stop the 60s timer, I can make a scene for turning Off after 60s, but then in graphic blocks i don't have a way to stop a scene, can I use stopScene?

    Please login or register to see this code.

    I want to change this variable only after 60s to manual, is that also possible? Is blocky that is 'limited' or want I want it isn't just possible?

     

    EDIT:

     

    I give it a try and it worked, in this scene it changes the variable to Running, and changing it again no manual state is inside the setTimeout. 

    Please login or register to see this code.

    So half of the work is done.

    - I want to turn on the Light A when Motion 1 detects movement and turn it off after 60s.

     

    I have two scenes, one that when Motion 1 detects movement, turn on the Light A and change variable from Manual to Auto

    The second scene is the one the code is on top, that when variable is == to Auto it changes it variable from Auto to Running, and after 60s turns off the Light A and changes its state from Running to Manual again, but only after the 60s.

     

    So my other question maintains, the second scene is running and waiting for changing its state to Manual and Power OFF the Lamp A, can i stop this scene in the middle with maybe fibaro:stopScene(9)?

     

    Maybe not:

    Please login or register to see this code.

    Please login or register to see this code.

    Please login or register to see this image.

    /emoticons/default_wink.png" alt=";)" srcset="https://forum.fibaro.com/uploads/emoticons/[email protected] 2x" width="20" height="20" />

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