Music Server Interface

Einklappen
X
 
  • Zeit
  • Anzeigen
Alles löschen
neue Beiträge
  • Gast

    Music Server Interface

    I just created the (ultra basic) first iteration of the music server interface plugin. Its goal is to provide an interface that acts like a fake Loxone Music Server, and provides back virtual inputs and outputs to the Miniserver so that you can get the actions the user does on the Loxone UI back into the Miniserver. The loxone Miniserver correctly recognizes it and will show the native UI pretty much everywhere.

    This plugin is probably the best companion of the LMS + Squeezelite plugins to create a Multi-Room Audio system (and the MS4Lox too!). So I hope Christian Fenzl can help me a bit on that and maybe extend the Squeezelite plugin to match the required inputs and outputs!

    There is still a lot to do, but hopefully some people can start testing it already Thanks!
  • Gagi
    LoxBus Spammer
    • 20.01.2018
    • 289

    #2
    Nice, this was long on my todo list as well, but i never had the time to actually start doing it ;-)

    Kommentar

    • hme0354
      MS Profi
      • 06.07.2019
      • 958

      #3
      You should also talk to hismastersvoice, the developer of MS4LOX.

      Why do you need the virtual inputs and outputs? For me, this is the same like the MS4LOX (allready working system). If you really want to make a fake Musikserver, it should work like the loxone musikserver.
      Zuletzt geändert von hme0354; 13.04.2020, 21:04.
      Smarthome: 1x Miniserver Gen. 2, 3x Relay Extensions, 1x Tree Extension, 1x DI-Extension, 1x Air Base Extension, 8x RGBW Tree Dimmer, 9x Touch-Tree, 1x Nano DI Tree, 10x Tree BWM
      Technik: IDM Aero SLM 3-11 mit HGL, MS4H mit 9 Zonen, 2x Loxberry, 2x RPI für Anzeige, Doorbird, Froggit WH2600, POE+ System für Peripherie, Gedad Luftgütesensoren, Deconz (Bridge + 2x BWM + 2x RGBW + 5 Smartplug)

      Kommentar


      • Gast
        Gast kommentierte
        Kommentar bearbeiten
        The plugin does not create a fake music server, it just fakes the Loxone Music Server interface, so you can use the native Loxone interface but with your preferred music server. That's why it brings back to the Loxone Miniserver the inputs and outputs of the real interface, so you can connect these actions to the commands of your music server.

        Traditionally, interfaces to custom (i.e. non-Loxone) music servers have been done by using radio buttons and other virtual inputs (something very similar to what is shown here (https://www.loxforum.com/filedata/fe...1442074010) - post (https://www.loxforum.com/forum/faqs-...=3825#post3825)). This plugin enables you to use the native interface but with your existing server backend (LMS+Squeezelite, MS4Lox, etc), so you get the best of both worlds.
        Zuletzt geändert von Gast; 13.04.2020, 22:12.

      • hme0354
        hme0354 kommentierte
        Kommentar bearbeiten
        ok. now I understand. Would be a great feature to combine it with MS4Lox.
        Zuletzt geändert von hme0354; 13.04.2020, 22:16.

      • Gast
        Gast kommentierte
        Kommentar bearbeiten
        Yes! Now that you mentioned hismastersvoice, I'd be super interested in having a set of virtual inputs/outputs to work with the MS4Lox too.

        Glad to hear you want to test it! It's in very early phases but it should be stable enough at least to bring the visualization in, play/pause, seek track and volume control. Happy to take bugs/issues through the forum and/or GitHub.

        I'm currently working in setting up my own music server, but I don't have all the required pieces yet nor haven't found the time to build it Once I have everything set up I will be able to test it myself also. (For now the testing was done by ensuring the required data was shown in Loxone Config).
    • hismastersvoice
      Supermoderator
      • 25.08.2015
      • 7193

      #4
      Nice Project...
      I understand the structure behind, becouse I tryed for a while by my self to do this.

      For good reason I never followed the connection to the Loxone app.
      I'm not sure, but since Loxone software is not public-licensed I think that using the interface in this way is not quite legal.
      Maybe it is legal, but I`m really not sure.

      Loxone has described and released the API to the MiniServer, but not to the MusicServer.

      Does anyone know the exact licensing of the MuiscServer in combination with a MiniServer?
      So we should be careful to use it that way.

      Let's say it carefully. It is questionable to use the work of the software developers of Loxone.
      Because it took them many hours/days/week of development for the part of the MusicServer in App.

      Sorry for being a party-killer.
      Zuletzt geändert von hismastersvoice; 13.04.2020, 22:21.
      Kein Support per PN!

      Kommentar


      • hismastersvoice
        hismastersvoice kommentierte
        Kommentar bearbeiten
        Your right about ther Weather4Lox Plugin. I´m also not sure there.
        I´d hope that it is legal, could be a nice feature. But I´m carefull about such things.
        I try to find out more about it...

      • hme0354
        hme0354 kommentierte
        Kommentar bearbeiten
        Great!

      • Gast
        Gast kommentierte
        Kommentar bearbeiten
        Thanks a lot hismastersvoice, I'm still a newbie here!
    • hismastersvoice
      Supermoderator
      • 25.08.2015
      • 7193

      #5
      Gast
      I´ll talk to another Mod, he don`t see any problems about licence etc.
      So you can go foraward.
      Kein Support per PN!

      Kommentar

      • hismastersvoice
        Supermoderator
        • 25.08.2015
        • 7193

        #6
        I installed the Pugin, and get a connection to the fake Music-Server.
        What I don´t understand, what to do with the I/Os, where is the conection to the LMS?
        The LMS controlls all Squeezelite PIDs so how to connect to these?
        Kein Support per PN!

        Kommentar

        • Gast

          #7
          You should connect the different virtual inputs provided by the plugin assistant (let me know if they don't work, I quickly coded that part) to commands that are issued to the LMS CLI (usually via port 9090).

          So, for instance, you get the [Zone 1, play] virtual input (that listens for a 1::‍play command), and connect it to the [LMS Squeezebox player 1] virtual output (that pushes a PL:AY:ER:MA:CC:00 play command). This way you cable the click of the play in zone 1 of the Loxone UI with a virtual output that issues the command "play" to the corresponding player (according to its provided MAC address). Something like that:

          Klicke auf die Grafik für eine vergrößerte Ansicht  Name: image.png Ansichten: 0 Größe: 6,0 KB ID: 244340

          In general I think all required data can be found through different commands issued to the LMS server.

          Kommentar


          • Morfeo
            Morfeo kommentierte
            Kommentar bearbeiten
            I have already created the entries to connect LMS4 + Squeezelite and they work. But how do I create virtual inputs for favorites? PL:AY:ER:MA:CC:00 favorites playlist play item_id: 1 \ n
            and the virtual outputs for the covers?

            Thank you very much for this wonderful work.
        • hismastersvoice
          Supermoderator
          • 25.08.2015
          • 7193

          #8
          Understand...
          but should it not be the better way to do it direct from LMS to the plug-in? Instead of the way over the MiniServer?
          If the volume change or title etc we can push it direct to the plugin.

          Can you give me a list of all the loxone commands that has to be send between the servers?
          Zuletzt geändert von hismastersvoice; 14.04.2020, 01:40.
          Kein Support per PN!

          Kommentar

          • Gast

            #9
            but should it not be the better way to do it direct from LMS to the plug-in?
            I thought a lot about this when doing the plugin, and I concluded that there is a wide range of people who already have their own music server setup. Some use LMS, but others may use Roon, Max2Play, etc., so it seemed the best to be able to let people plug their existing systems into the interface. In fact, people have often created already visualizations in the Loxone UI using Radio options, selectors, etc. emulating those, so it should be only a matter of removing those virtual inputs and use the ones from the plugin instead, and everything should magically work with the native Loxone UI.

            Can you give me a list of all the loxone commands that has to be send between the servers?
            I haven't fully investigated that; still setting my own music server in the LoxBerry (with lots of issues BTW). I'm giving a try to [LMS + Squeezebox server + Squeezelite], which I think it's the setup provided by MS4Lox.

            I have been using this as a reference when doing my early tests: https://github.com/elParaguayo/LMS-C...ter/LMS-CLI.md. I'm aware of play, pause and time (to seek to a particular position), and playlist index for queue index; but I'm unsure for other stuff like obtaining album, artist, title, etc. Here's where I hope Christian Fenzl can help us a little bit as he worked on the LMS gateway in his Squeezelite plugin.

            Kommentar

            • hismastersvoice
              Supermoderator
              • 25.08.2015
              • 7193

              #10
              Thanks...
              I know the LMS-CLI best, I also have coded a Gateway for the MS4L that sends all the Data Titel/Artist Play/Stop/Pause Syncs etc etc to the MiniServer.
              It listen to the CLI Port and acts on every change. It works as a native Linux-Serice and it sould be easy to integrate the push of Data to the Plugin.
              The Max2Play and Roon also use LMS and could work with such a Listener, as lonfg we know the CLI-Port.

              Got it work native on the MS4L...
              Play/Pause works fine Volume always show 0,0 and is not updated
              Titel/Artist works only if you do a control from the Loxone App, if you do eg a title change with an external App it dosn`t update.
              Next try ist Album Cover..

              Great Work!
              Zuletzt geändert von hismastersvoice; 14.04.2020, 08:30.
              Kein Support per PN!

              Kommentar


              • hismastersvoice
                hismastersvoice kommentierte
                Kommentar bearbeiten
                [WSCK] Received message: audio/1/volume/21
                [HTWS] Unknown command: audio/1/volume/21

                The Msg are shown but as an Unkown command

              • hismastersvoice
                hismastersvoice kommentierte
                Kommentar bearbeiten
                Found the issue...
                It works if you klick the Speaker Icons with +3 -3 steps but if you use the Slider with an absolute value it shows an the Unknown Command

              • Gast
                Gast kommentierte
                Kommentar bearbeiten
                Good catch hismastersvoice. I noted it also to fix it!
            • hismastersvoice
              Supermoderator
              • 25.08.2015
              • 7193

              #11
              Album Cover not show up, the skript receive the URL but nothing changes.

              [DGRM] Received message: 1::setAlbum::https://i.scdn.co/image/ab67616d0000...3376e1e95c6980

              Also with other commands that show up when I use 3th Party Apps e.g.
              [DGRM] Received message: 1::setTitle::What's Luv

              Nothing change in the Loxone App.
              Zuletzt geändert von hismastersvoice; 14.04.2020, 09:05.
              Kein Support per PN!

              Kommentar


              • hismastersvoice
                hismastersvoice kommentierte
                Kommentar bearbeiten
                Ok I changed it, but I get these from you Auto-Created I/Os.
                There is in 2 VQs setAlbum so maybe the creation of the VQs are not correct.

              • hismastersvoice
                hismastersvoice kommentierte
                Kommentar bearbeiten
                Artwork is OK now

              • Gast
                Gast kommentierte
                Kommentar bearbeiten
                Copy-paste I noted it for fixing too
            • hismastersvoice
              Supermoderator
              • 25.08.2015
              • 7193

              #12
              To the topic licence...

              Loxone Music Server Licenses
              ------------------------------------------
              Loxone Music Server is based on Linux, using parts of GPL & Opensource Software as platform for our own Server Services.
              Our added Loxone services for communication, Miniserver specific tasks and mobile app handling are delivered in binary form.
              Our binaries are in the intellectual property of Loxone Multi Media GmbH as copyright holder.
              Your are allowed to use our software in a commercial way.
              So as long we don`t change any binarys from Loxone everthing is fine.
              Kein Support per PN!

              Kommentar

              • Gagi
                LoxBus Spammer
                • 20.01.2018
                • 289

                #13
                I also think that it should be fine as we also not linking against their libs.

                What's still a grey area is whether an API itself itself can be protected as well. Orcacle and Google are fighting over this for many years now and there is still not any decision on this...
                In case the API is also part of the license and we are not allowed to use this without license, Loxone might also have a problem then as they are most likely also violate the GPL of the LMS because of that...

                That said i'm not a lawyer, these are just my 2 cents...

                Gagi

                Kommentar

                • Gast

                  #14
                  I just published 1.0.1 with the bugfixes for the issues that were found. It can be downloaded/installed from https://github.com/mjesun/loxberry-m...ases/tag/1.0.1. That should enable the volume sliding, which I agree was a bit annoying

                  Kommentar

                  • hismastersvoice
                    Supermoderator
                    • 25.08.2015
                    • 7193

                    #15
                    Thanks for update, try it later...

                    another thing with refreshing Title/Artist
                    The script is showing the msg but there is no upadte in the App, ,if I press stop/play or next index it updates the Title/Artist
                    [DGRM] Received message: 1::setArtistIE NACHMITTAGSSHOW

                    But that is not allways, sometime it updates normal.


                    Also the Zone stops after a while by themself, these only happens when I use the Plugin.
                    If I stop the plugin/musikserver the zone playes like before without stoping.
                    Zuletzt geändert von hismastersvoice; 14.04.2020, 17:08.
                    Kein Support per PN!

                    Kommentar

                    Lädt...