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.

    mpd/mpc titel display on MM

    Scheduled Pinned Locked Moved Unsolved Troubleshooting
    6 Posts 2 Posters 3.8k Views 3 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.
    • C Offline
      co8
      last edited by

      Hey there,

      I am using mpd mpc player with my Mirror and I am looking for a way to display the current titel within the mirror.
      Any ideas how I could manage that?

      Right now I am using a playlist and 3 buttons prev, next and play/stop with a python script. The title would be stdout on the terminal. Somehow I have to redirect it to the mirror/website.

      I am not really good with javascript or programming in general, just a bit basics that’s it. If you need mor info let me know.

      BR
      co8

      1 Reply Last reply Reply Quote 0
      • strawberry 3.141S Offline
        strawberry 3.141 Project Sponsor Module Developer
        last edited by

        you could run the python script as a childprocess in the node_helper and then listen on stdout, when you receive data you could send a socket notification to your module and then display it on the mirror

        Please create a github issue if you need help, so I can keep track

        1 Reply Last reply Reply Quote 0
        • C Offline
          co8
          last edited by

          Hi strawberry,

          Thank you for your input. When I said, I am not really good with javascript or programming, I meant my knowledge is down to zero.

          To run a childprocess in node_helper I found this blog,
          http://krasimirtsonev.com/blog/article/Nodejs-managing-child-processes-starting-stopping-exec-spawn

          Does this goes in the right direction?

          1 Reply Last reply Reply Quote 0
          • strawberry 3.141S Offline
            strawberry 3.141 Project Sponsor Module Developer
            last edited by strawberry 3.141

            thats exactly what i meant but you would go for spawn not exec

            just post your progress and questions, the others and I will help you creating your module

            Please create a github issue if you need help, so I can keep track

            1 Reply Last reply Reply Quote 0
            • C Offline
              co8
              last edited by

              Thanks.
              I will definitely read into this.
              Also found this for better understanding http://www.hacksparrow.com/difference-between-spawn-and-exec-of-node-js-child_process.html

              1 Reply Last reply Reply Quote 0
              • strawberry 3.141S Offline
                strawberry 3.141 Project Sponsor Module Developer
                last edited by

                maybe the module of paviro can give you a kickstart https://github.com/paviro/MMM-Facial-Recognition/blob/master/node_helper.js

                he’s using pyshell, you can use this as well

                Please create a github issue if you need help, so I can keep track

                1 Reply Last reply Reply Quote 0

                Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                With your input, this post could be even better 💗

                Register Login
                • 1 / 1
                • 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