MythMPD

Posted: July 7th, 2007 | Tags: | 15 Comments »

MythMPD is a simple MPD client for MythTV. It shows the current playing song and the playlist and allows for the basic controls. It cannot (yet?) add to or edit the playlist.

I wrote this because a) I wanted it and b) other people seem to want it. I don’t really know much C, so it was a learning experience and is most likely shitty code. But, hey, it works.

I use MythTV at home, not so much to watch (dodgy Spanish) TV, but as a home media centre to watch DVDs and downloads, listen to music, etc in the salón. The existing MythMusic module is not so hot and the ecowarrier in me doesn’t like having the TV on all the time just to change music. To that end, I started using MPD to listen to and change music from the powerbook. However, I missed being able to use the remote control to pause and change volume, so MythMPD was born. I can now blindly use the remote to control the music in the living room, resorting to another mpd client when I need to add more music to the playlist.

Update: moved source to github.


15 Comments on “MythMPD”

  1. 1 spacetweek said at 21:34 on July 9th, 2007:

    That passed about 3.2 kilometros over my head.

  2. 2 James Grossmann said at 01:44 on August 22nd, 2007:

    SWEET! I was thinking about switching my music to mpd, and I use Myth for my home media system. I would like to be able to control the different sound systems in my house from myth. I would like to help if I can, but I’m definitely worse at programming than you are. (I still may try to hack something together…)
    Thanks!

  3. 3 James Grossmann said at 23:01 on August 23rd, 2007:

    What I’m envisioning is a slight redesign to make mythmpd work like mythmusic. It seems that this is a desire listed on the feature wishlist, and could easily cover a number of the desires expressed on that list. http://www.mythtv.org/wiki/index.php/Feature_Wishlist_%28Plugin_Addons%29
    I’m doing some reading and analyzing of code in preparation for coding myself. I hope to have some psuedocode put together by the end of the afternoon. If you have any pointers or would like to work together on this, you can email me at cctsurf | at | hotmail | dot | com.
    Thanks!

  4. 4 ferg said at 10:42 on February 28th, 2008:

    Nice work! I’m just trying to integrate my MythTV box with MPD and Icecast in a doomed to failure attempt to have multi-room synchronised music listening goodness. I’ll have a play with your plugin.
    Thanks
    Ferg

  5. 5 Stephane said at 22:57 on April 9th, 2008:

    Hi ! I’m actually trying everything I can related to MythTV, and planning on a plugin developpment. Your plugin seams to have a code easy to understand, and also be started from the “MythHello” plugin (am I right ?). It interrests me as me MythHello doesn’t work … And also because I’d love to write my own plugin, but I will test yours as soon as I have MPD setup ! But I’d like to report you 2 issues : I use a widescreen (and a Wide Theme), and the text isn’t good placed in your plugin, maybe you placed it static from the left border on a 4/3 screen ? And 2nd : when I hit “escape” to leave the plugin, the whole MythTV Frontend exists (is it crashing ?) Anyway, thanks and keep doing the good job !

  6. 6 Andreas Böhler said at 18:05 on July 24th, 2008:

    Very nice plugin that saved my day! Unfortunately, it segfaults on exiting. Here is a quick fix for it:
    In mythmpd.cpp on line 38 insert (in a new line, of course):
    statusTimer = Null;
    right after “timer->start(1000);” but before the “}”.
    When exiting, MythMPD tries to delete an uninitalized Timer-Object, therefore segfaulting. We now initalize the timer with Null.
    I also changed the UI-Layout a bit, drop me a line if you’d like to see the changes or a patch for the source at: andy (dot) boehler (at) gmx (dot) at!

    Greetings,
    andy

  7. 7 Net Wolf said at 23:05 on December 20th, 2008:

    Thanks for posting your plugin. I’m running it and it works perfectly.

    The defualt theme didn’t really fit into my Myth setup so I’ve have written an mpd-ui.xml file for the MePo MythTV theme.

    You can see it at: http://netwolfuk.wordpress.com/mythmpd-mepo-theme/

    Cheers, Net Wolf.

  8. 8 ThE_BuRK said at 00:36 on January 5th, 2009:

    how about rewriting mythmusic to add this feature as an src update .. or to be honest … rewrite mythmusic.. :P even tho .. ive been thinking about doing this hack for a while.. so good idea and nice that someone started … ill do everything i can to help ypu out if you need it.. :)

  9. 9 rhormaza said at 08:07 on September 1st, 2010:

    very nice plugin mate!!…just what I wanted….I tested it in mythtv 0.23 and It worked with some mods (just basics one as now I have no idea how mythtv architecture works) …I’ll try to made more changes later on to see if this plugin can get better because, for me, mpd is very handy when you wanna control your music from a mobile client and get the info there such as current song, playlist, etc.

  10. 10 wavemaker said at 22:15 on October 16th, 2010:

    rhormaza, I’m very interested how you made it work. i get compilation errors….

  11. 11 Learnincurve said at 09:07 on December 14th, 2011:

    Any plans to resurrect this? I’m looking for ways to make spotify work through MythTV and by far the best so far is a mopidy backend running on the mythtv box. A Mythtv MPD client to control it would be SWEET!

  12. 12 mackers said at 12:08 on December 14th, 2011:

    Yes, I believe someone is working on an update. Keep an eye on github.

  13. 13 James Mills said at 08:58 on December 28th, 2011:

    I’m looking for an update too.
    I’m running MythTV 0.24.1 and the
    source from github doesn’t compile.

    –JamesMills

  14. 14 Martin said at 20:15 on August 27th, 2012:

    I so agree with Learnincurve about the MythTV + Mopidy (MPD) solution! Hope someone makes git compile on 0.24 or even better 0.25

  15. 15 Chris Debenham said at 01:55 on April 23rd, 2013:

    I’ve cloned the git repo and made a bunch of changes.
    It now works with mythtv 0.25 and 0.26
    It also supports loading playlists and playing all songs by the selected artist
    See https://github.com/cjd/mythmpd


Leave a Reply