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

Jan, can it be that ghost effect?

Maybe one day we catch it

Posted (edited)
38 minutes ago, jgab said:

 

I have the last fw, I just don't update my signature...

 

I don't think it's your sensors that is the problem - it is something with your ER6 instance/code.

Can you save it as a .fqa and PM me the QA so I could have a look at it and debug it?

 

Yes will PM. Meanwhile:

(1) I reinstated my ER5 code and am measuring a near consistent 30sec delay when using trueFor(). The workaround (for me) is to subtract 30s 😕 I have not noticed this before as things just work well enough.

(2) I did measure latency on the All-In-One QA (AOQ) too between 20s and 28s... Does that tell us something...

(3) Is there a series of tests or diagnostic routines / health check QA that could accompany ER. For example your routines on this page for latency and timing - 

 

Edited by gurpal2000
  • Topic Author
  • Posted

    I didn't see a delay? My concern was the early trigger (~3min instead of 5min) that I think depends on something that have broken in your ER6 instance.

     

    A motion sensor has 2 states, breached and safe.

    You can configure a sensor parameters how long time it should be "safe" after a breach before actually turning safe. That delay is common to be 30s but can be changed.

     

    The trueFor rule you have measures from it going safe. In your log I didn't see delays for that?

     

    A diagnostic tool is an interesting idea. Will think about that.

    Meanwhile I will look at you PM.

    9 hours ago, Neo Andersson said:

    Jan, can it be that ghost effect?

    Maybe one day we catch it

    My first thought too, but there seems to be something broken in his ER6 instance.

    Didn't Fibaro fix this earlier? You still see it?

  • Topic Author
  • Posted (edited)

    Tada! It was a general bug in ER6 that I had introduced that affected all property function on tables of deviceIds,

    like {88,99}:breached, or in your case the stair.sensor value.

    I had in my own running ER6 instance, but it is an obscure rule that seldom triggers so I hadn't noticed.

     

    Try v0.0.53 and see if it behaves better.

    For the delays, remember that the trueFor(00:05,sensors:safe) measures from all the sensors going safe.

    I'm planning to add an optional  trueFor log so it's easy to see when it starts to wait. Now it is when you see the trueFor rule trigger but there is no thumbs up or down following, because it has started a wait() for the time specified.

     

    Thanks for helping me find the bug!

    Edited by jgab
    • Like 1
  • Topic Author
  • Posted

    So, the double log statement in the beginning of your log is because of rule expression used for logging, ex

    Please login or register to see this code.

    The 'log' function is a Lua print statement, and it will output
     

    Please login or register to see this code.

    However, the rule function as default returns the value of the expression executed. For a rule it's the rule object, but for our log above, the log function returns the string it prints.
    That means that the rule("log('Hello')") also returns the string "Hello" which then outputs in the console (again) as
     

    Please login or register to see this code.

    so we get it twice.

     

    We want rule(...) by default to log the value computed, but when the expression is a ER log call we get the console output twice.

    If we want our rule call to not log the return value we can add the flag no_expr_result=true

    Please login or register to see this code.

    and we will only get the log from the log print.

     

    It's common to use expr("log(....)") in the code to get logs when the rules as loading, in that case we can create a "silent rule" function that don't print the result

    Please login or register to see this code.

    and use it as

    Please login or register to see this code.

    or make a dedicated log function supporting color

    Please login or register to see this code.

    and call

    Please login or register to see this code.

     

    Posted
    4 hours ago, jgab said:

    I didn't see a delay? My concern was the early trigger (~3min instead of 5min) that I think depends on something that have broken in your ER6 instance.

     

    A motion sensor has 2 states, breached and safe.

    You can configure a sensor parameters how long time it should be "safe" after a breach before actually turning safe. That delay is common to be 30s but can be changed.

     

    The trueFor rule you have measures from it going safe. In your log I didn't see delays for that?

     

    A diagnostic tool is an interesting idea. Will think about that.

    Meanwhile I will look at you PM.

    My first thought too, but there seems to be something broken in his ER6 instance.

    Didn't Fibaro fix this earlier? You still see it?

    Yeah, randomly...Not that often though.

    Posted (edited)

    @jgab ok will try the new ER! So i'm trying to use ER updater

    What do I press and should there be a popup or something in the logs ;-)

    Update gives:

    [2025-10-28] [20:05:09] [ERROR] [QUICKAPP421]: Please select both EventRunner6 and version

     

    (separately: It did take an unusual time (IMHO) for the 2nd and 3rd dropdowns to populate when first installed - they were blank onInit even when I select ER6 in the first dropdown)

     

    image.png.df18502e8450044d8c2ea546e284795b.png

     

    In the meantime, I have updated manually and will monitor over next few days or so.

     

    Edited by gurpal2000
    Posted (edited)

    @jgab Happy to report that timings are looking great!

     

    The Aeotec MS6 has two parameters that I think affect return-to-safe time (tallying with my measurements).

     

    Param 3 - PIR time settings - lowest possible is 10s

    Param 8 - Timeout of awake after the Wake Up CC is sent out - lowest possible is 10s

     

    thx

     

    Edited by gurpal2000
    Posted

    Jan, this error does't have ERROR notification

    Please login or register to see this code.

    error in rule corrected 

     

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

    Jan, this error does't have ERROR notification

    Please login or register to see this code.

    error in rule corrected 

     

    Thanks, will check.

    Posted

    Jan I don't know hat to fix if I assume this error belongs to rule 180?

    Please login or register to see this code.

    I added some logs to check if I have a nil value

    Please login or register to see this code.

     

    All triggers with value

    Please login or register to see this code.

     

  • Topic Author
  • Posted

    No, the  signals that the rule was defined (ok)
    The problem is in the rule that follows. It should be a better error message, so if you can find the rule and post it I can fix it.

    Posted

    Jan both rules 180, 181 are having the green vink!

    It's a stupid error I overlooked it!

    "| &"

     

    Posted

    @jgab Is it possible to add rule that will check if there is new version of ER6 and new function in your updater that will be possible to call from ER6 for automatic ER6 update?

    Posted

    Perhaps a kind of subscription to get an email if there is an update for all your beautifull QA's, services, for HC3 users?

    • 2 weeks later...
    Posted
    On 9/1/2025 at 1:38 PM, jgab said:

    Here is a ER5 compatible module system - put it in a QA file. It defines a global lua function loadModules.
    From main do

    Please login or register to see this code.

     

    Please login or register to see this code.

     

    Hello, tried to make the modules set-up as in ER5, but can not get it to work. Does someone have an example? I get the following error, clearly I am missing something 

     

    ./include/main.lua:8: attempt to call a nil value (global 'loadModules')

     

    • 2 weeks later...
    Posted

    Jan should be marked as error?

    Please login or register to see this code.

     

  • Topic Author
  • Posted

    Please login or register to see this code.

     

     

    Please login or register to see this code.

    Posted

    Jan yes I know but it is in debug not marked as an error it give the error discription as you can see.

    Posted

    Jan how I can stop a QA (not ER6) from running instead of deleting it?

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