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

Incorrect global variable value


Question

Posted

Hi!

 

I have a problem, i set a value to a global variable using a Virtual device for later usage.

I check in the variables panel and they are correct.

 

But then further on when i "get" them using a scene i get a different value. Like an old value.

 

After restart of my HC2 its correct again. Do i got a memory issue?

 

 

5 answers to this question

Recommended Posts

  • 0
Posted

Can you post code? I tried and everything worked fine so it does not seem like a firmware flaw.

  • 0
  • Inquirer
  • Posted

    This is one example were i get this issue.

     

    Please login or register to see this link.

     

    I use the alarm clock VD to set eg. the day/time.

     

    When i then run the scene it shows in the log something different and also act incorrectly. (Trigger the scene.)

     

    eg. This weekend i had the alarm set on Monday at 7AM (Since i want to sleep), but still on sunday it run anyway.

    I then checked the panel and and add debug statement in the scene.

    The panel showed Monday but still the debug printed sunday.

     

    I restart the HC2 and then the scene printed the correct variable again.

     

    This happened 3 times now...

    • 0
    Posted

    @KristianO, I could not reproduce this error in any isolated case. You may want to contact author of this device to help you, I simply do not see the error when using all actions required, it must be something specific for this code/installation rather than general bug. maybe try delete the testing of global variables from main loop? I do not think this would cause an issue like that but there is nothing else not common in rest of the code.

    • 0
  • Inquirer
  • Posted

    Im pretty sure it will happen again and i will then post a snapshot from the variables panel and the scene debug screen at the same time.

    If it shows different, whats wrong then?

    • 0
    Posted

    Maybe it is the interface thing? Can you look up API when it happen?

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