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

Minimote With VIrtual Device


Question

Posted

Hi There Lua experts 

 

Im following this guide for the minimote setup

Please login or register to see this link.

 

looks great i have copied and pasted the code and the virtual device as below 

 

--[[
%% properties
351 sceneActivation
%% globals
--]]
 
--------- Your Device ID's Here ---------
 
local virtualDevID = 368  --Edit these values!!
local minimoteID = 351
 
------ Do not edit below this line ------
 
local buttonPressed = fibaro:getValue(minimoteID, "sceneActivation")
fibaro:call(virtualDevID, "pressButton", buttonPressed)
 
 
 
the problem is when i press a button i get this error
 
[ERROR] 18:27:00: line 14: unexpected symbol near '&'
 
 
that is this line
local buttonPressed = fibaro:getValue(minimoteID, "sceneActivation")
 
i cant work out what is wrong with this line im guessing something have changed in the current version but would love to get this woeking

 

4 answers to this question

Recommended Posts

  • 0
Posted

If you don't really need the virtual device, I recommend my procedure instead...

Please login or register to see this link.

If you need the VD then I can't help you at the moment, but maybe when I have some more time. I don't want to insult the originator of the VD post but it's not the clearest explanation available. As you've found out, it also isn't copy/paste. I can already tell you this: a part of the solution is an ordinary lua scene, not a VD. I think you copy/pasted code for the scene in a VD. Although both use lua as a language, they are quite different.

  • 0
  • Inquirer
  • Posted

    thanks i was using the other way before but the idea of a remote control of it was nice

    Please login or register to see this image.

    /emoticons/default_smile.png" alt=":)" srcset="https://forum.fibaro.com/uploads/emoticons/[email protected] 2x" width="20" height="20" />

     

    thanks anyway

    • 0
    Posted

    Hi Mad-Cat,

     

    Thanks for asking your question.

     

     

    The problem is with the " things that have been inserted into the code by our web development software - sorry about this!  These can be replaced with a '.

     

    I have corrected the tutorial.  If you try again it should work fine.  I'm sorry about the inconvenience caused.

     

     

    Happy Automating!

     

    Adam Bewsher

    • 0
  • Inquirer
  • Posted

    Yep thanks it works a treat now... thanks niceway of doing it although i have no idea how the link links them

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