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

Clone virtual devices


robmac

Question

It was obvious really but if you also have a mental block of how to create replicas of a virtual device to speed up setup.

create a backup

Create a new blank Virtual device to make into a clone yyyy

Get the ids of the one to copy xxxx and the one to make yyyy from a browser

xxx.xxx.xxx.xxx/api/virtualDevices

Create anther virtual device called the Cloner

add a button

put this LUA in

edit the ids

Please login or register to see this code.

Hit the button and hope

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

robmac, I have not tested but I like the idea.

Please login or register to see this image.

/emoticons/default_icon_biggrin.gif" alt=":-D" />

Link to comment
Share on other sites

  • 0
Guest Kuuno

tested and worked well for me!

great tool!

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" />

Link to comment
Share on other sites

  • 0
  • Inquirer
  • Saves a bit of effort.

    I think you could generate scenes also and possibly even edit config values in code.

    Next is to create a java or c# app so we can dump scenes and virtual devices to a file and load to another HC2.

    Link to comment
    Share on other sites

    • 0
    Guest Kuuno

    i wondered if you could use send email function and send the code to admin email.

    this would be a way to export

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • You can do it in c#, perl or java.

    I gave it a quick hack but don't really need it and need some family time so won't complete.

    Some c# code to get you started if you want to give it a try.

    Easy to load to a file and then read back later.

    Please login or register to see this code.

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