MythTV and XBMC integration

OK, my system works like this. MythTV for most purposes, video/TV etc. but then I also want iPlayer (HD) on my telly, and as my mythbox is hooked to the stereo, last.fm in my living room. It seems to me the best way to get these is with XBMC.  So I have XBMC installed as per previous posts, the iplayer source defined and it set to load straight to the video screen. But I want some better integration, so there are a few steps:

Make them looks the same. So project grayhem widescreen theme for Myth, project mayhem HD for XBMC.
Launch XBMC from myth. Tricky this one, as if I just launch XBMC infront of mythtv, due to the odd way XBMC handles remotes, signals will keep going to mythtv aswell, hilarity ensues… So the solution is to have an XBMC menu option in myth that does the below:

<type>MENU_MEDIA_LIBRARY</type>
 <text>XBMC</text>
 <action>EXEC /full-path-to-script/myth2xbmc.sh</action>
 </button>

And the myth2xbmc.sh script looks like this:

#!/bin/bash
killall mythfrontend.real;xbmc;mythfrontend &

And yes, it’s an awful hack. Any better suggestions, well the comment forms at the bottom of the page ;-)

Actually, I’ve customised more than just the above in my mythtv menus (no need for the optical disc menu on my revo for a start). I did this by creating my own menu theme in /usr/share/mythtv/themes , following the lead of the DVR menu theme but it’s more based on the default. I’ll put mine online if I can find somewhere good to upload the .tgz.

Getting back to myth from XBMC. Ok, so I mentioned XBMC handles remotes funny. Basically it used Lircmap.xml to map your remote’s keys, to XBMC keys (historically based on an XBOX controller), then it maps its standard keyset to actions in Keymap.xml. If you copy the default to your userdata folder, then you can edit what buttons do what. It’s a bit of an odd setup really, took me a while to work out what was going on there! Anyhow, so the above script means when we exit XBMC it’ll restart the frontend an boot us back to the main menu. So I just added the XBMC.Quit action to the power and home buttons on my remote. Job done.

Advertisements

3 Responses to “MythTV and XBMC integration”

  1. […] to do something differently… « VDPAU testing tool – nV News Forums MythTV and XBMC integration […]

  2. Conrad Says:

    regarding your ugly hack to deal with remote signals going to both mythtv and xbmc, see:

    http://shrunklink.com/ecru

    -this lircrc file uses “mode” when launching/quitting applications (in this case amarok/mythtv-frontend) so the signals only go to whichever application the “mode” is set to…

  3. david pitcher Says:

    how did this go? Does this load straight into the iplayer part of xbmc and does it close into mythtv?

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: