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

All off scene trigger


Sullyinwagga

Question

Hello, 

 

How do you trigger an all off scene without a trigger? 

 

What i mean is can you trigger from a virtual button created on the app to start an all off scene say when ypu leave the house or go to bed 

Link to comment
Share on other sites

6 answers to this question

Recommended Posts

  • 0

What do you mean by trigger all scenes?

Is it means to run all scenes one time?

Please notice that when you "trigger" the scene without real trigger, the scene unable to determine which device triggered. 

Could you post an example what exactly scene should do?

Edited by cag014
Link to comment
Share on other sites

  • 0
  • Inquirer
  • I meant trigger an "ALL OFF" scene, eg, turn all lights off.... I want to have a button on the Fibaro app on my device (phone or tablet)and also link it to google assistant the say "hey Google.... all lights off

     

    Also if I know how to do this I can create other scenes eg, Party... BBQ.... Holiday etc

     

    Sorry if it wasn't clear no the best at describing things sometimes :-)

     

     

    Link to comment
    Share on other sites

    • 0

    Set the trigger as time-based, and set the time in the past, this scene will then only be triggered manually, unless you set up another scene that runs this scene or, set it up with google assistant, or using IFTTT. 

    • Like 1
    Link to comment
    Share on other sites

    • 0

    You can do it with scene or Virtual device, but let's start with scene...

    Please login or register to see this code.

    Change devId to your real device ID  number

    Now since the scene doesn't have any triggers it will work only by running the scene manually.

    The scene will appear on your phone or tablet. Just run it....

     

    Link to comment
    Share on other sites

    • 0

    Hi.

     

    I´m using this lua code.

    It switches all lightning off if its on. Even if you add a light device afterwards you dont have to edit the code...

     

    I´ve named it goodnight :) and set it to manual..

     

     

    --[[
    %% properties
    36 value
    %% weather
    %% events
    %% globals
    --]]

    if (fibaro:countScenes() > 1) then fibaro:abort() end; 
    local i = 0 
    local maxNodeID = 1000 
    for i = 0, maxNodeID do 

    if fibaro:getValue(i, "isLight") == "1" then

    if (fibaro:getValue(i, "value") >= "1") 
    then 
    local DeviceName = fibaro:getName(i); 
    local RoomName = fibaro:getRoomNameByDeviceID(i) 
    fibaro:call(i, "turnOff"); 
    fibaro:debug("Switched off device "..i.." "..DeviceName.." "..RoomName); 
    else 
    local DeviceName = fibaro:getName(i); 
    local RoomName = fibaro:getRoomNameByDeviceID(i); 
    fibaro:debug("Device "..i.." "..DeviceName.." "..RoomName.. " was already off");
          
    end 
    end 
    end

     

     

    If you add this, it pauses sonos speakers..Change id to yours

     

    fibaro:call(147, "pause"); 
    fibaro:call(148, "pause");
    fibaro:call(50, "pause");
    fibaro:call(51, "pause");

    Edited by Baloba
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • 10 hours ago, Danial said:

    Set the trigger as time-based, and set the time in the past, this scene will then only be triggered manually, unless you set up another scene that runs this scene or, set it up with google assistant, or using IFTTT. 

    Thanks Mate, just what I was looking for, just gotta try it with Google now 

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