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 not performing all actions


Figlio

Question

Hi all,

 

I run into a problem with a scene behind a button in a VD I m using to set my living room lights at a certain dim level. I have many buttons each with a different setting of the lights. The problem is i need to run the scene three times to get the lights set at the correct dim level.

 

In the screenshot below the debug of the thee times i ran the scene are shown.

 

To start, I manually set the lights at 100% and then turned them all off.

 

How can i solve this?

 

Note: I use a MCO Home control pad to manually turn on the light. There is a scene that sets the dim level at 75% when the light is switched on manually. I use the Global SceneStart to determine whether the mco home button is switched on manually or by this scene.

 

Please find my scene here:

 

Please login or register to see this code.

 

 

 

Please login or register to see this link.

Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0

A few things that might be relevant. This is a part of your code, I added comments:

 

Please login or register to see this code.

There is no need to turn on the dimmer, if you want to set a certain level. Just set the level.

 

For dimmers in general, value means:

 

0 = off

1 = lowest level = 1 % brightness (-> Check parameters of the actual device, it might be configurable).

99 = highest level = 100 % brightness (-> Check parameters of the actual device, it might be configurable too).

 

There is no "value 100".

 

Special case: you can *set* the value to:

255 = previous level = same as "turnOn" = what the dimmer remembers, last time it was on.

After setting it to 255, the dimmer reports the actual level (for instance: 75).

 

Also, there might be some delay between the setting and the reporting, so please add some delay...

 

Can you try this instead?

 

Please login or register to see this code.

What are you trying to achieve with that global variable? Are you trying to limit the number of running instances of this scene?

 

If this does not help, do you have other scenes or VDs that control the same device IDs?

Edited by petergebruers
Link to comment
Share on other sites

  • 0

Shouldn't it be local schuifpui under the triggers instead of schuipui?

Link to comment
Share on other sites

  • 0
17 minutes ago, jimicr said:

Shouldn't it be local schuifpui under the triggers instead of schuipui?

 

You mean...

Please login or register to see this code.

Should be...

Please login or register to see this code.

That is correct, I've updated my previous post... The script will still work without this change, because DimSchuifpui will be "global" instead of "local". Well spotted!

Link to comment
Share on other sites

  • 0
  • Inquirer
  • Thanks for helping out guys.. With your suggestions I made it work! J

     

    two things seem to indeed have been wrong.

    First the local "schuifpui" suggested by @jimicr

    Second the calling value On on the Dimmer as suggested by @petergebruers

     

    @petergebruers The global variable is used for another scene which is used when the lights are switched on manually. The scene sets them to 75%. I use the global variable to determine whether the scene was started by another scene (1) or manually (2).

     

    The following code works for me:

    Please login or register to see this code.

     

     

    Link to comment
    Share on other sites

    • 0
    10 hours ago, Figlio said:

    @petergebruers The global variable is used for another scene which is used when the lights are switched on manually. The scene sets them to 75%. I use the global variable to determine whether the scene was started by another scene (1) or manually (2).

     

    Thank you for explaining... I am not sure this is what you want, but if you want a dimmer to turn on at a certain level then for "Dimmer 2" you have another option, Parameter 19:

     

    19. Forced switch on brightness level

    If the parameter is active, switching on the Dimmer (S1 single click) will always set this brightness level.
    Available settings:
    0 - function disabled

    1-99 - percentage level of brightness Default setting: 0

     

    The advantage of this parameter over scripting? With scripting, your dimmer will, at some times, turn on at the wrong level, then your script corrects it a second later, and the light will appear to "blink".

     

    It gets tricky if you want different levels at different times, for instance 20 during the night and 75 during the day, you'll have to use a script that changes parameters... If you are interested, I use this on Dimmer 1but it should be possible to adapt it to work with Dimmer 2.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • 12 hours ago, petergebruers said:

     

    Thank you for explaining... I am not sure this is what you want, but if you want a dimmer to turn on at a certain level then for "Dimmer 2" you have another option, Parameter 19:

     

    19. Forced switch on brightness level

    If the parameter is active, switching on the Dimmer (S1 single click) will always set this brightness level.
    Available settings:
    0 - function disabled

    1-99 - percentage level of brightness Default setting: 0

     

    The advantage of this parameter over scripting? With scripting, your dimmer will, at some times, turn on at the wrong level, then your script corrects it a second later, and the light will appear to "blink".

     

    It gets tricky if you want different levels at different times, for instance 20 during the night and 75 during the day, you'll have to use a script that changes parameters... If you are interested, I use this on Dimmer 1but it should be possible to adapt it to work with Dimmer 2.

    I do not have any parameters te set. The dimmers are not fibaro, I use three qubino dimmers and three domitec wave dimmable led lamps. I am not aware of being able to set parameters for them, hence i use a scene to do so.

    Link to comment
    Share on other sites

    • 0

    @Figlio Thank you for elaborating! I've checked the manual of my old Qubino Dimmers, and indeed they do not have a "Forced switch on brightness level".

     

    For sake of completeness, they do have parameters that influence the maximum and minimum brightness. I often set the minimum level so that I am certain that it glows visibly when I set the dimmer really low in code (e.g. set it to 1%). This also avoids people dimming down too much, then thinking the light is "off" while in reality is not. You can also turn a dimmer into an on-off switch, by setting min to 98 and max to 99...

     

    Parameter no. 60 – Minimum dimming value Available configuration parameters (data type is 1 Byte DEC):

     Default value 1 (Minimum dimming value is1%)

     1- 98 = 1% – 98%, step is 1%. Minimum

     dimming values is set by entered value. NOTE: The maximum level may not be lower than the minimum level! 1% min. dimming value is defined by Z-Wave multilevel device class.

     

    Parameter no. 61 – Maximum dimming value Available configuration parameters (data type is 1 Byte DEC):

     Default value 99 (Maximum dimming value is 99 %)

     2- 99 = 2% – 99%, step is 1%. Maximum

     dimming values is set by entered value. NOTE: The maximum level may not be lower than the minimum level! 99% max. dimming value is defined by Z-Wave multilevel device class.

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