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


Key no 2 on a dimmer


Recommended Posts

Guest Cirion
Posted

I want to use Key No 2 on a dimmer for controlling a scene and turning off all lights. Can it be done?

The actions I want done is:

On single click:

Run Scene "Welcome" (and it will turn on several lights around the house at the perfect %)

On double click:

Turn off all lights in the house.

I do not want single click to turn off lights, to avoid kids and others from accidentally turning off all lights in the house.

Posted

Cirion, just use scene activation and assign only values of Scene Activation parameter you are interested in.

Guest imparator
  • Topic Author
  • Posted

    j.nowacki do you have a example for it ?

    and can you use it on all of the dimmer modules versions ?

    Posted

    impaprator - do you have hc2 or hclite? With hc2 you can use sceneactivation with LUA. Let me know and I will give you an example.

    Lauri

    Guest imparator
  • Topic Author
  • Posted

    hi lauri

    i have a hc2

    thx

    Posted

    Hi,

    then you have to make LUA:

    --[[

    %% properties

    71 sceneActivation --DIMMER ID

    %% globals

    --]]

    local startSource = fibaro:getSourceTrigger();

    if (

    ( tonumber(fibaro:getValue(71, "sceneActivation")) == 15 ) --DIMMER KEY NO2 ACTION

    or

    startSource["type"] == "other"

    )

    then

    fibaro:startScene(2); --SCENE ID YOU WANT TO RUN

    end

    Here you have to change ID71 according to your own dimmer ID. And 15 is the switch number 2 value according to this:

    Input S2:

    holding down ID 22

    releasing ID 23

    double click ID 24

    (depends on parameters 15 value - 1 = double click active)

    triple click ID 25

    If parameter no.19 set to 0 (default), then one click ID 26 is sent

    If parameter no.19 is set to 1 following IDs are sent:

    switch from “off” to “on” ID 20

    switch from “on” to “off” ID 21

    If you have any questions, please ask.

    Guest Cirion
  • Topic Author
  • Posted

    LUA is Greek to me...

    I'm trying to make sense of this.

    I have now made a LUA Scene like this:

    Please login or register to see this code.

    My dimmer ID is 11 and the Scene ID is 11 (not shure why they are the same).

    Parameter 19 on the dimmer is 0 Default.

    The scene is active, and clicking or double clicking the S2 button, does not do anything.

    If I run the Scene, it activates Scene 11.

    According to your info I want S2 ID 26 to start my Scene 11 and S2 ID 24 to turn off all lights in my house. I'm not shure where to put those numbers.

    I do not understand this LUA code, is there a list of commands somewhere?

    [ Added: 2014-11-10, 17:51 ]

    Im testing this code, and it seems SceneActivation does not work on my HC2.

    I only get a debug when I start/run the scene, not when pressing buttons.

    I have tried on another dimmer with dual buttons, same result.

    Please login or register to see this code.

    [ Added: 2014-11-10, 18:33 ]

    Device kind:Dimmer

    Device type:FGD211 Dimmer

    Producer:Fibargroup

    Version:1.7

    Did I invest too early in Fibaro to do this?

    [ Added: 2014-11-10, 18:38 ]

    From what I can read in the dimmer manuals, Scene activation was introduced in the 1.9 - 1.11 versions.

    [ Added: 2014-11-10, 18:39 ]

    I have investet 3000€ in Fibaro modules and HC2...

    Is there no way to do this without changing the modules?

    [ Added: 2014-11-12, 13:13 ]

    Went out and bought another dimmer V2.2

    Scene Activation is now an option.

    Used my scene 11 to turn on the lights I want at the perfect %.

    Created a new scene 146 to turn off all lights in the house (one by one).

    24 is doubleclick

    26 is singleclick

    If anyone singleclicks the button, lights go on where I want them. If anyone clicks it again, nothing happens. Perfect for kids who play with the button. And no guests will ever turn off the light by touching the button by accident.

    If I doubleclick the button (and it needs a really fast doubleclick) all lights in the house turns off.

    Please login or register to see this code.

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Reply to this topic...

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