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

prevent the roller shutter from coming down if the window is open


Question

Posted (edited)

Please login or register to see this code.

Please login or register to see this code.

Thanks

 

--[[
%% properties
123 sceneActivation
123 value
%% globals
--]]
open = fibaro:getValue(472, "value");
fibaro:debug(open);
local startSource = fibaro:getSourceTrigger();
if ( tonumber(fibaro:getValue(472, "value")) > 0 ) then
    fibaro:call(123, "open");          
end

Edited by paolo
add request

8 answers to this question

Recommended Posts

  • 0
Posted

create block scene and convert so you see what you need.

472 value to add

//Sjakie

  • 0
  • Inquirer
  • Posted

    Please login or register to see this code.

    thanks

     

    --[[
    %% autostart
    %% properties
    472 value
    %% weather
    %% events
    %% globals
    --]]

    local startSource = fibaro:getSourceTrigger();
    if (
     ( tonumber(fibaro:getValue(472, "value")) > 0 )
    or
    startSource["type"] == "other"
    )
    then
        fibaro:call(123, "stop");
    end

     

    • 0
    Posted

    You should operate the scene in the app NOT the device. If opreate the device you overrule everything.

    Mine are:

    I should add if window is open >>stop blind

    if window is closed >> permission to open / close blind

    If you do also add  value 123

    //Sjakie

     

     

     

     

     

    • 0
  • Inquirer
  • Posted
     

    Please login or register to see this code.

    • 0
    Posted

    ok, so the trigger works. if you command the device it stops.

    What happens if you activate the scene on remote? 

    What you activate on the app, Scene or VD

    //Sjakie

    • 0
  • Inquirer
  • Posted

    on the app i simply operate directly on device command to close, no scenes no virtual devices.

    • 0
    Posted

    I think the working method is that:

     

    You write a scene what sets the roller shutters local and remote protection on when someone open the window, and another one (or in the same) turn off the two protection on roller shutter if the window closed.

    • 0
  • Inquirer
  • Posted

    thanks Milan Takacs

    i suppose the correcty lua code is

    local myrsFB = xxx
    fibaro:call(myrsFB, "setProtection", 1, 1);

     

    1,1 - 1,0 for Rf protection and 0,0 - 2,0 for local protection? (on-of)

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