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.