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


Recommended Posts

Posted
43 minutes ago, jgab said:

This rule

Please login or register to see this code.

is missing commas after the R1 and R2 keys

Please login or register to see this code.

 

I will try to implement a better error message instead of crashing...

 

thanks, here another error, and i have no clue where to search

 

 

Please login or register to see this code.

 

 

 

Gettiing this error

 

Last err: Expr Runtime: attempt to get length of a number value putprop for k,v in pairs(RGBW_data) do k:color = v.$globalColorMode.color end ^

 

 

 

Just now, Neo Andersson said:

thanks, here another error, and i have no clue where to search

 

 

Please login or register to see this code.

 

 

 

Gettiing this error

 

Last err: Expr Runtime: attempt to get length of a number value putprop for k,v in pairs(RGBW_data) do k:color = v.$globalColorMode.color end ^

 

 

 

This rule is working at my house

  • Topic Author
  • Posted (edited)

    Please login or register to see this code.

    does not work.
    Maybe you mean

    Please login or register to see this code.

    ?

    1 minute ago, jgab said:

    Please login or register to see this code.

    does not work.
    Maybe you mean

    Please login or register to see this code.

    ?

    Think about $globalColorMode as fibaro.getGlobalVariable("globalColorMode")

    Then

    Please login or register to see this code.

    doesn't make sense, but 

    Please login or register to see this code.

    does...

     

    Edited by jgab
    Posted
    2 minutes ago, jgab said:

    Please login or register to see this code.

    does not work.
    Maybe you mean

    Please login or register to see this code.

    ?

    v.$globalColorMode.color working at home without a problem, but okay i will try here at customers house to use the other one.

    Posted
    9 minutes ago, Neo Andersson said:

    v.$globalColorMode.color working at home without a problem, but okay i will try here at customers house to use the other one.

    Please login or register to see this code.

  • Topic Author
  • Posted (edited)
    15 minutes ago, Neo Andersson said:

    v.$globalColorMode.color working at home without a problem, but okay i will try here at customers house to use the other one.

    I'm sure it doesn't - unless you have an old ER5 with bad error messages for that case...

     

    4 minutes ago, Neo Andersson said:

    Please login or register to see this code.

    I think it's complaining about

    Please login or register to see this code.

    What is k?

    TRy

    Please login or register to see this code.

    Edited by jgab
  • Topic Author
  • Posted
    12 minutes ago, jgab said:

    I'm sure it doesn't - unless you have an old ER5 with bad error messages for that case...

     

    I think it's complaining about

    Please login or register to see this code.

    What is k?

    TRy

    Please login or register to see this code.

    Is white and red defined as tables with 3 values?

    Just now, jgab said:

    Is white and red defined as tables with 3 values?

     

    ...and I can conform that v.$globalColorMode.color

    works... but it is unintended and I would not use that - it may change in the future when I make stricter error checks in the parser.

    Posted
    2 minutes ago, jgab said:

    Is white and red defined as tables with 3 values?

    this is the table that it is looping through

     

    Please login or register to see this code.

  • Topic Author
  • Posted
    1 minute ago, jgab said:

    Is white and red defined as tables with 3 values?

     

    ...and I can conform that v.$globalColorMode.color

    works... but it is unintended and I would not use that - it may change in the future when I make stricter error checks in the parser.

     

    So, k:color = <something that is not a table with 3 values>

    will create the error message "Expr Runtime: attempt to get length of a number value putprop"

    SO what is red and white defined as?

     

    Please login or register to see this code.

     

  • Topic Author
  • Posted (edited)

    next version throws an error

    "setColor expects a table with 3 values"

    if k:color = <something that is not a table with 3 values>

    Edited by jgab
    Posted

    @jgab I have a pack man in the system who is consuming memory.

    It's hard to detect what is the cause, perhaps as with earlier fw of Fibaro?

    I notice that if usage of memory is high I need another meter to get in before light switching on.

    To avoid later switching on our lights I want if possible:

    in ER5 a rule if free memory < 10% HC3 should restart.

    Thanks 

     

    Posted
    35 minutes ago, jgab said:

     

    So, k:color = <something that is not a table with 3 values>

    will create the error message "Expr Runtime: attempt to get length of a number value putprop"

    SO what is red and white defined as?

     

    Please login or register to see this code.

     

    Please login or register to see this code.

  • Topic Author
  • Posted (edited)
    3 minutes ago, Neo Andersson said:

    Please login or register to see this code.

    Yes, but where do you define it? They need to be defined before you define RGBW_data.
    If you run this

    Please login or register to see this code.

    just before 

    Please login or register to see this code.

     

    Do you get the color tables?

    Edited by jgab
    Posted
    10 minutes ago, jgab said:

    Yes, but where do you define it? They need to be defined before you define RGBW_data.
    If you run this

    Please login or register to see this code.

    just before 

    Please login or register to see this code.

     

    Do you get the color tables?

    Ahh okay, that was the bad order,,,Ohh kinda difficult to find errors foe me..maybe when i will have an up and running VD code for ER5 one day.

    Thanks so far

  • Topic Author
  • Posted
    2 hours ago, Sjakie said:

    @jgab I have a pack man in the system who is consuming memory.

    It's hard to detect what is the cause, perhaps as with earlier fw of Fibaro?

    I notice that if usage of memory is high I need another meter to get in before light switching on.

    To avoid later switching on our lights I want if possible:

    in ER5 a rule if free memory < 10% HC3 should restart.

    Thanks 

     

    What number are you looking at?

    Free memory is ~%100-%Used space. So you mean %Used space > 90 ?

    Posted

    yes is okay >90%

  • Topic Author
  • Posted
    50 minutes ago, Sjakie said:

    yes is okay >90%

    Something like this? checks every 5min

    Please login or register to see this code.

     

    Posted

    @jgab

    Jan wich alarm rule should work, because none of them seem to work for me

     

    Please login or register to see this code.

     

    Posted

    Thanks Jan, HC3 does't restart at all.

    Please login or register to see this code.

     

    Posted
    46 minutes ago, Neo Andersson said:

    @jgab

    Jan wich alarm rule should work, because none of them seem to work for me

     

    Please login or register to see this code.

     

    UPDATE, okay found in the desciption

  • Topic Author
  • Posted (edited)
    5 hours ago, Sjakie said:

    Thanks Jan, HC3 does't restart at all.

    Please login or register to see this code.

     

    Ok, that is a command that needs credentials - which makes sense.

    Please login or register to see this code.

     

     
    Edited by jgab

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