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

Condition for making a scene work in a specific time frame


Question

Posted

Hi guys!

I'm trying to create a scene that makes it possible for the lights outside my bathroom to light up when I breach a motion sensor. However I only want this to happen -say between 23:30-06:00. I cant find a condition in block scenes that can do that. Any input?

cheers!

/

Fred

11 answers to this question

Recommended Posts

  • 0
Posted

I think you have to use lua for this...

  • 0
Posted

Hi Frederik,

This can be done by using Block scenes; just use from "Timers" section the option "Interval based".

You then define the From- and To hours value, and change "Every 1 hour" into "Every 0 hour". This way it will work fine.

Note that you need to create 2 Scene's here; one that powers on the light if sensor is breached, the other one that powers off the light is sensor is Safe again. The due time of the 2nd script I use is 5 mins. later compared to the first script, to avoid that the lamp will always remain on if there's a timing problem.

Please see the attachments as example.

I know that in LUA you probably can do it in one script, but I didn't find the time yet myself to figure out how to program the script. Since it works fine for me I left it for what it is right now until I have more spare time.

Best regards,

Mark

Please login or register to see this attachment.

Please login or register to see this attachment.

  • 0
Posted
Hi Frederik,

This can be done by using Block scenes; just use from "Timers" section the option "Interval based".

You then define the From- and To hours value, and change "Every 1 hour" into "Every 0 hour". This way it will work fine.

Note that you need to create 2 Scene's here; one that powers on the light if sensor is breached, the other one that powers off the light is sensor is Safe again. The due time of the 2nd script I use is 5 mins. later compared to the first script, to avoid that the lamp will always remain on if there's a timing problem.

Please see the attachments as example.

I know that in LUA you probably can do it in one script, but I didn't find the time yet myself to figure out how to program the script. Since it works fine for me I left it for what it is right now until I have more spare time.

Best regards,

Mark

Sorry for my wrong answer

  • 0
  • Inquirer
  • Posted

    Thank you very much! So kind of you to put in the effort for me. I will try this tonight. I also wonder if you can use the triggered lamp like it isn't a part of a scene at daytime? i.e. If you want to have the light turned on let's say between 1700-2200?

    [ Added: 2015-01-29, 14:50 ]

    no worries, Boomx!

    [ Added: 2015-01-29, 15:00 ]

    ok. So you do not use your triggered lamp to do anything else at daytime - it just turns on when breached at night?

    /f

    • 0
    Posted

    Hi Frederik,

    To my knowledge you can only do this when using either Block scenes or LUA script. You can set up as many scenes and scripts as you would like, no matter if the lamp is included in any of those or not.

    I hope I understood your question well, else just let me know and I'll adjust the given answer.

    Copy to Boomx,

    Don't worry my friend, mistakes are also opportunities to learn

    Please login or register to see this image.

    /emoticons/default_icon_wink.gif" alt=";-)" />

    [ Added: 2015-01-29, 15:05 ]

    Hi Frederik,

    On my side this lamp won't do anything during the day, but if I would then I just define the scene or script and execute.

    As long as the times between the different scenes or scripts do not overlap you won't encounter any issue.

    Br. Mark

    • 0
  • Inquirer
  • Posted

    ok. Perfect! Thank you for all your replies! Cheers!

    /F

    • 0
    Posted

    What if i want a scene to only turn on the light when the sun is down and the motion sensor is breached.

    i have HCL, so it needs to be a block scene.

    I am thinking about someting with a variable. so could set 'dark' to 1 if the sun is down.

    But for this to be usefull, i would like to set it to dark=1, 20 min before the sun goes down and wait til 20 min past sunrise to set it back to dark=0.

    I only see options for setting from sundown and from before sunrise.

    • 0
    Posted

    Hi I did this, not based on the sunset, but via Lux - I have one Lux sensor outdoor, setting the variable to "day" or "night" based on the Lux set, then I use this variable in the scene together with "sensor breached".

    • 0
    Posted

    Hi ldplusse,

    I don't think this is possible with HCL, unfortunately

    Please login or register to see this image.

    /emoticons/default_icon_sad.gif" alt=":-(" />

    This can only be achieved with a LUA script.

    Though, the workaround as said by Acho will work ofcourse but always requires some continuous manual effort in my understanding.

    Best regards,

    Mark

    • 0
    Posted

    i have lux in my Fibaro motion sensors.

    But they are not all that precise.

    will play around with it.

    [ Added: 2015-01-29, 20:20 ]

    i dont understand this scene selection.

    If i can select 'at sunset', why should there be any information about time.

    Should it be possible to set the variale 'dark' to '1' at sunset, and create and opposite for sunrise.

    But what about the 'time' in that box selection?

    Please login or register to see this attachment.

    • 0
    Posted
    i have lux in my Fibaro motion sensors.

    But they are not all that precise.

    will play around with it.

    [ Added: 2015-01-29, 20:20 ]

    i dont understand this scene selection.

    If i can select 'at sunset', why should there be any information about time.

    Should it be possible to set the variale 'dark' to '1' at sunset, and create and opposite for sunrise.

    But what about the 'time' in that box selection?

    When you choose 'at sunset' the time will be ignored. In version 4 the time will disappear.

    Please login or register to see this image.

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