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


  • 1

Back on developing Squeezebox Plugin


robmac

Question

OK dusting down a few of my user plugins that are not officially supported.

 

First one is my squeezebox plugin. I had only spent a few hours building this back when the user plugins was supported in Beta so it is still raw.

 

It creates a device for all players connected to the server. I will give it a brush up and test. If anyone else wants to risk a version sign up below. It may be a few weeks as I only expect to get a few hours a week on this max.

 

I will also fix up the Samsung TV one that I have that changes the off/on to control a switch device rather than putting TV in standby so the network does not get turned off. With this one you can always control your TV.

 

 

Please login or register to see this attachment.

Please login or register to see this attachment.

Please login or register to see this attachment.

Please login or register to see this attachment.

Link to comment
Share on other sites

20 answers to this question

Recommended Posts

  • 0

The topic has been moved from "

Please login or register to see this link.

" to "

Please login or register to see this link.

".

 

Temat został przeniesiony z "

Please login or register to see this link.

" do "

Please login or register to see this link.

".

Link to comment
Share on other sites

  • 0

Hi there,

 

I moved this topic to Developer subforum as it seems to be still in development ; )

Link to comment
Share on other sites

  • 0
10 minutes ago, I.Srodka said:

Hi there,

 

I moved this topic to Developer subforum as it seems to be still in development ; )

 

Hello @I.Srodka,

 

Is this indirect confirmation that user plugins can be sent to Fibaro for approval and distribution with new firmware releases?

Because if it is then this is really GREAT news and I will prepare my self to join the train! :-) 

Link to comment
Share on other sites

  • 0
  • Inquirer
  • 48 minutes ago, I.Srodka said:

    Hi there,

     

    I moved this topic to Developer subforum as it seems to be still in development ; )

    Hi and welcome,

     

    It certainly is still in development. Nobody else would want it yet.

     

    If when I have an alpha I want to drop the files here for others to test will that be OK?

     

    Robert

    54 minutes ago, Fibaro said:

    The topic has been moved from "

    Please login or register to see this link.

    " to "

    Please login or register to see this link.

    ".

     

    Temat został przeniesiony z "

    Please login or register to see this link.

    " do "

    Please login or register to see this link.

    ".

    That is cool.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  •  

    Repeat this here as I had assumed most people knew this. I assumed nobody bothered because they wanted to keep their HC2 standard.

     

    Mine has a non fibaro plugin on it now. Not sure what side effects that will cause but it is my risk.

     

    If you know how to fix everything you can work out how to remove any bad boys you create if you do.

     

    Please login or register to see this link.

     for docs 

     

    follow some common sense with your namespace

     

    use you favorite tool to call the api when you have a plugin. I use Postman

     

    http://xxxxxxxxx/api/plugins/install

     

    POST

     

    two parameters that need to be set

    overwrite value 1

    file  value your zipped file of plugin

     

     

    you can always go and get the fibaro plugins to understand how it all glues together

     

    Enjoy and develop something brilliant to prove to Fibaro that letting us at it is the best way to stay ahead. 

    Link to comment
    Share on other sites

    • 0

    just a side note, when developing plugins it make definitely sense to define some actions in types/xml (oh well, and implement all necessary function's mapped these actions) in the lua's. In that way one can easily use plugins in lua, e.g. fibaro:call(BongoPluginID, "playFromUri", "blah.balh:80")
     

     

    Link to comment
    Share on other sites

    • 0
    On 5.08.2017 at 1:47 PM, robmac said:

    If when I have an alpha I want to drop the files here for others to test will that be OK?

     

    Yes, you can post it here, but obviously we cannot take responsibility for plugins created by others so users will be installing it on their own.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Update on developing a basic plugin.

     

    Basic wiring done. Framework is not bad and certainly easy enough.

     

    Only issue so far is a lack of css classes for the switch component to make toggle style mute, power and play/pause buttons and generally a lack of info on use of the UI components. The plugin control width is set small in the css so not a lot of space to play with.

     

    Seems stable. It is certainly worth putting a big label for basic info messages on the component while developing. In my case it helps to see all the messages coming in from the server.

     

    Only had a few hours on it. So  far the plugin connects to the server and creates a device per player.

     

    Players are basic but both server and players can be controlled from scenes. Players update quickly with track updates and actions caused through other interfaces. Low CPU usage ( 3 to 5% just now with all players playing and reporting a good stream of messages) and low impact on memory but not loading a library view yet. I am subscribing to far too many messages just now so cpu will go down.

     

    Needs a bit of a tidy up and add the translations next

     

    After that I need to add a place to add a z-wave power switch id for each player. This will replace the squeezebox plugin I currently use. It will allow external amps etc can be controlled automatically when the players are switched on and off.

     

    Then the hardest bit on this small interface is how to put the library view together.  Possibly a card index a-z style filter. I have 850 albums and 28K tracks so even then it going to need paging and search. Anyone done this on a plugin yet.

     

    Last task will be to create some sort of zone device to sync players on. I am thinking a button on the server to create as many zones as you want.  Then each can hold a synchronization set that can be synced and un-synced from scenes.

     

    If you are competent with code, plugin development is certainly worth having a go at. I am not in practice and only do the odd hack these days. I am sure people could create some brilliant plugin devices. A lot better than scenes and virtual devices.

     

    If we can convince Fibaro to load a few more LUA libraries there is not much that you could not do. A lot of power in this hardware doing nothing just now.

     

     

    Please login or register to see this attachment.

    Please login or register to see this attachment.

    Please login or register to see this attachment.

    Edited by robmac
    Link to comment
    Share on other sites

    • 0
    On 5.08.2017 at 3:31 PM, robmac said:

    use you favorite tool to call the api when you have a plugin. I use Postman

     

    http://xxxxxxxxx/api/plugins/install

     

    Hope, Fibaro will not remove it as they did it on the interface.

     

    Please login or register to see this attachment.

     

    There is

    Please login or register to see this link.

    .

    And

    Please login or register to see this link.

    .

    Edited by szmyk
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Something small that I was not worrying about was the playlist icon.  Just was not displaying. Path in the property looked fine but it did not display.

     

    As the main purpose of this plugin is for control players from scenes so that they can be synced and play playlists. Also as I use external amps, to link each player with a power switch device to control the amp on off when the player switches on and off.

     

    Finally got round to looking into it and the solution was not that difficult.

     

    On inspection of the playlist icons in the browser, I noticed that the icon had an extra bit of path that was added by the underlying code. Changed the icon for the tracks and guessed that you need an ip and port set on the device that the playlist is on and all fixed. Not sure how this will work for remote but will worry about that later.

     

    So a small hint for others if they are playing with the list set as a playlist.

     

    Please login or register to see this attachment.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Work on this had to stop for a while due to proper work but back on with it.

     

    All stable but needs a bit of polishing.

     

    When added set the IP and library name and the plugin gets all of the players and creates a device for each player.

     

    Player settings allow you to select a switch for your amp and one for your DAC if they are external. The plugin will switch on and off when the players are turned on or off whatever way the players are switched on.

     

    Automation from scenes works but needs some documentation and refining.

     

    Secured servers not supported

    --server actions

    powerAll
    turnOn
    turnOff
    stopAll
    pauseAll 
    muteAll
     syncAll
    unSyncAll
    setVolumeAll
    setShuffleAll
    setRepeatAll   

     

    --player

    power
    turnOn
    turnOff
    stop
    pause
    next
    back
    forward
    rewind
    volume
    mute
    syncPlayTo
    unSyncPlay
    setShuffleTo
    setRepeatTo
    playRandom
    playAlbum
    playDirectory
    playTracks
    playPlaylist
    playUrl

     

    Interface for creating groups WIP.  Possibly an interface for playlist selection but not really the point of the plugin.

     

    Display all good on web interface  but:

     

    1) No icon in mobile apps. Not sure why yet as have made icons of all sizes

    2) Now playing image does not show on ipad app.

    3) Now playing and playlist icons not updating in android phone app.

     

    Please login or register to see this attachment.

    Please login or register to see this attachment.

    Please login or register to see this attachment.

    • Like 1
    Link to comment
    Share on other sites

    • 0

    +1 @T.Konopka is there any plans to enable agian the ability to add 3-rd party plugins? Or can some of them be evaluated and added to fibaro library?

    Link to comment
    Share on other sites

    • 0

    @korniza , if you are asking about personal plugins then no, we are not bringing this feature back. At the moment, there is no way to add a 3rd party plugin without FIBARO. The plugins are added by us.

    However, we have the

    Please login or register to see this link.

    where official partners add their Virtual Devices and Scenes that can be used with their devices in FIBARO System.

    I know that this is not the same as a plugin, but this allow users to use 3rd party devices that are not (yet) integrated with the system via plugins.

    Link to comment
    Share on other sites

    • 0

    Dear @T.Konopka ,thank you for your answer. 

    My main problem of missing plugins, is that we can not declare a VD as light or a switch so to be included it with other same type devices.  For example a wifi plug or a NFC device.

     

    Edited by T.Konopka
    Don’t – Quote an entire article or another user’s post. Do – Quote the exact sentence or short paragraph that you want to discuss.
    Link to comment
    Share on other sites

    • 0
    37 minutes ago, korniza said:

    we can not declare a VD as light or a switch so to be included it with other same type devices

    This has been submitted as an improvement some time ago. It is waiting for verification ;)

    Link to comment
    Share on other sites

    • 0

    Yes yes !!! Since years... I had opened a bugtracker ticket for that since years...

    So really, this will come for VD ??? In next time ?? This would be the greatest improvement of the box since a long time and for me will clearly replace the Personal plugin !!

    Link to comment
    Share on other sites

    • 0

    Anglais

    Please login or register to see this code.

     

     

    Please login or register to see this code.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Sorry fibaro dropped plugins and I no longer use fibaro controller.

     

    If you want good support for squeezebox

    • OpenHab
    • Hubitat
    • homeseer
    • and others

    all support.

     

     

     

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