• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

MMM-Sonos - To show what your SONOS is playing.

Scheduled Pinned Locked Moved Entertainment
29 Posts 17 Posters 21.5k Views 16 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    Luttich @Atreo
    last edited by Mar 22, 2017, 9:11 PM

    @Atreo same for me

    1 Reply Last reply Reply Quote 0
    • C Offline
      cederstrom Module Developer @Atreo
      last edited by Apr 6, 2017, 2:30 PM

      @Atreo Have you tried the fix in the “Known issues” section of the README? https://github.com/Snille/MMM-Sonos#known-issues

      1 Reply Last reply Reply Quote 0
      • C Offline
        cohron
        last edited by Apr 21, 2017, 6:55 PM

        Guess I’m total noob but I havent figured out exactly how to install MMM-Sonos.

        1. I’m confused on installing and running node-sonos-http-api part. Does it get installed on /usr/local/lib/node_modules (I dont have that folder) but I do have /home/pi/MagicMirror/node_modules.

        2. MM is on rPI3b using the default installation from the readme but the the documentation on the api says i should install the latest nodejs. do i need to update/install? I went to https://nodejs.org/download/release/latest/ and it looks like 7.9.0 is the latest. i assume i install this on the MM rPI also. I’ll have to figure out how to git that too if so.

        3. I have my mm.sh file that auto-starts MM using pm2. Do I add a line in the mm.sh file to auto run the api on boot?
          my mm.sh
          cd ~/MagicMirror
          DISPLAY=:0 npm start

        1 Reply Last reply Reply Quote 0
        • S Offline
          Snille Module Developer
          last edited by Apr 21, 2017, 9:01 PM

          @cohron First you need to “install” the node-sonos-http-api. You can put the node-sonos-http-api on the RPi I think. I have not tried that. I have mine installed on another server. But just try it, do the following (obs I have not tried this):

          cd ~
          git clone git@github.com:jishi/node-sonos-http-api.git
          cd node-sonos-http-api
          npm install --production
          npm start
          

          Now, see if you can get your zones via the link: http://yourmagicmirrorip:5005/zones
          If you do, you should be able to point your config to http://localhost
          And you should see something playing, if it is playing. :)

          Now you need to make sure the http-api is running all the time.
          Use the same procedure as for the MagicMirror.
          When you have the MagicMirror and http-api running type pm2 save (if you are using pm2).
          Otherwise you have to add it to your startup manually.

          I hope this helps a bit at least. :)

          If you cant find it, make it and share it!
          Modules: MMM-homeassistant-sensors, MMM-Modulebar, MMM-Profilepicture, MMM-Videoplayer

          C 1 Reply Last reply Apr 21, 2017, 9:32 PM Reply Quote 0
          • C Offline
            cohron @Snille
            last edited by Apr 21, 2017, 9:32 PM

            @Snille

            All right, love trial and error. Got it all up and running on my MM rPI!!!
            Through ssh pi@192.168.0.207 (my MM ip address)

            cd ~ //which puts me at /home/pi
            pi@magicpi:~ $ git clone https://github.com/jishi/node-sonos-http-api.git

            cd node-sonos-http-api
            npm install --production
            npm start

            verify, open a browser, point to your MM’s IP like so:
            http://192.168.0.207:5005/zones
            you should see a page full of sonos related text, if so the hard part is done…

            create another pm2 script named sonos.sh in ~ directory
            cd ~
            sonos.sh file contents:
            cd ~/node-sonos-http-api
            DISPLAY=:0 npm start

            pm2 start sonos.sh
            pm2 start mm
            pm2 save

            now just do the normal git for the sonos module
            pi@magicpi:~/MagicMirror/modules $ git clone https://github.com/Snille/MMM-Sonos.git

            fill in your config, this is mine:
            {
            module: ‘MMM-Sonos’,
            header: “Playing on SONOS”,
            position: “top_center”, // This can be any of the regions, best results in center regions
            classes: “default everyone”,
            config: {
            // See ‘Configuration options’ for more information.
            showStoppedRoom: false,
            showAlbumArt: true
            }
            },

            I also copied your awsome custom css content!

            D B 2 Replies Last reply Apr 15, 2018, 6:20 PM Reply Quote 0
            • S Offline
              Snille Module Developer
              last edited by Apr 21, 2017, 9:36 PM

              @cohron So it’s working now? Congrats! Great work! :)

              If you cant find it, make it and share it!
              Modules: MMM-homeassistant-sensors, MMM-Modulebar, MMM-Profilepicture, MMM-Videoplayer

              J 1 Reply Last reply Apr 26, 2017, 2:07 AM Reply Quote 0
              • J Offline
                j.e.f.f Project Sponsor Module Developer @Snille
                last edited by Apr 26, 2017, 2:07 AM

                This post is deleted!
                1 Reply Last reply Reply Quote 0
                • B Offline
                  brandongomez
                  last edited by Jun 19, 2017, 11:54 PM

                  Great module! I am new to all of this and have the module working as intended. I listen to SiriusXM, Google Play and Spotify through Sonos.

                  Google Play looks great and pulls the Artist and Track Title correctly. However, SiriusXM is sending everything together. Is there a way to format what SiriusXM sends me?

                  For example, if I go to http://IP_Address:5005/zones when using Google Play, I see… {“currentTrack”:{“artist”:“Aretha Franklin”,“title”:“Respect”,“album”:“I Never Loved A Man The Way I Love You”,“albumArtUri”

                  But if I put on a SiriusXM channel, it looks like this… {“currentTrack”:{“title”:“BR P|TYPE=SNG|TITLE Cold Little Heart|ARTIST Michael Kiwanuka|ALBUM”,“albumArtUri”

                  As a result, the SiriusXM channel shows nothing for the Artist and “BR P|TYPE=SNG|TITLE Cold Little Heart|ARTIST Michael Kiwanuka|ALBUM” for the Track. Would love to get it to show something like “Cold Little Heart, Michael Kiwanuka” instead.

                  Any help is appreciated. Thanks!

                  1 Reply Last reply Reply Quote 0
                  • S Offline
                    Snille Module Developer
                    last edited by Jun 20, 2017, 8:44 AM

                    Hi! Hm… Looks like the SiriusMX information is not coming out in JSON format correctly from the SonosAPI.
                    I think you may have to contact Jimmi about this. Open an issue here: https://github.com/jishi/node-sonos-http-api/issues and describe your problem. As soon as the “output” is in correct JSON format, it should be working. Usually hes quick in fixing things. :)

                    Good luck.

                    If you cant find it, make it and share it!
                    Modules: MMM-homeassistant-sensors, MMM-Modulebar, MMM-Profilepicture, MMM-Videoplayer

                    1 Reply Last reply Reply Quote 0
                    • DesaydroneD Offline
                      Desaydrone
                      last edited by Jan 24, 2018, 2:35 PM

                      Hello,

                      I got two sonos (for now) but on my mirror i only want to show one of this two. I don’t find how to do that, is ti possible ?

                      yawnsY 1 Reply Last reply Jan 24, 2018, 3:14 PM Reply Quote 0
                      • 1
                      • 2
                      • 3
                      • 1 / 3
                      • First post
                        Last post
                      Enjoying MagicMirror? Please consider a donation!
                      MagicMirror created by Michael Teeuw.
                      Forum managed by Sam, technical setup by Karsten.
                      This forum is using NodeBB as its core | Contributors
                      Contact | Privacy Policy