I know I’m probably late to the game, but I just got myself a Raspberry Pi. Currently I have a Myth TV front end in the living room run by an old laptop, my goal is to replace it. Here I share some of my experiences with the pi.
Getting the RPi
I got my Pi for $50AUD shipped from element14. That includes the board and case. This is also the new 512MB RAM Model B. Previously it was only 256MB. To get started, you also need a 5V 0.7A micro-USB power supply (comes with most smart phones) and a spare SD card. Both of these I have spares lying around so I didn’t need to buy them.
The biggest drawing point of the Pi is that it has hardware accelerated h.264 1080p video and XBMC support. There are three main XBMC distros to choose from: OpenELEC, Xbian and Raspbmc. I chose OpenELEC after reading a few reviews, but generally each of them have a good following. Installation was pretty simple, just follow the guide to flash an the image onto an SD card.
As an aside, I also researched installing MythFrontend, but there seems to be no effort to port MythFrontend to the RPi. MythFrontend requires X server and is possibly a resource hog. XBMC on the Pi draws directly onto the frame buffer so there’s no overhead of a windowing system. MythTV also doesn’t support the OpenMAX video acceleration API used by the Pi to show hardware accelerated video.
There was a bit of drama with flashing the SD card. After flashing my 8 GB microSD with full-SD adapter and powering on the pi, there was just a red led and nothing appearing on screen. After googling for answers, it seems that it happens when the pi doesn’t like you SD card. I got an alternate 1 GB full size SD card and that worked.
The initial boot up process takes around 2 mins while subsequent boot up takes less that 1 minute. This is actually faster than my old setup with laptop, but that was booting full linux mythbuntu PXE over 100 Mbps network.
Initial impressions were that the menus were slightly laggy but completely usable. I tried adding a network folder and it took forever. The video files I tried also didn’t play and was returning unknown error. Looking at the logs, turns out I had some zip/rar files which XBMC was trying to extract every time I played a file. It’s probably looking for subtitles but stopping a file from playing due to that seems disingenuous to me. OpenELEC exposes various important directories over windows shares (SMB) so grabbing the logs was just a matter of going to \\openelec – Couldn’t be any simpler.
h.264 mkvs played well, but I noticed a 1080p movie I was trying out was stuttering every few seconds. Googling reveals various shortcomings like DTS causes stuttering as it was not accelerated. The decoding is built into hardware, and the only thing stopping it from being used is licensing which Raspberry Pi guys are negotiating with DTS Inc. about. You can also apparently get by this issue using pass-through, if your HDMI TV supports DTS decoding. Back to this movie, the audio was however encoded in Dolby Digital Plus, which shouldn’t suffer from this issue. After some trial and error, I found that the culprit was the soft-subtitles. Turning it off stops the stutters. The movie is still watchable but not the silky smoothness you would expect. Hopefully, this is just a efficiency issue with XBMC and could be overcome in later version. SD videos play completely fine even without hardware help. I tried some RMVB videos but it seems XBMC on the Pi doesn’t have the correct codecs compiled for it and hence it did not work.
As Myth TV Frontend
All digital broadcasts in Australia uses MPEG-2. Initially there was no support for hardware-accelerated MPEG-2 on the Pi, but on popular demand, the RPi devs allowed you to purchase a license to activate the hardware decoding. The license is a reasonable 2 GBP which equates to around $3 AUD. You submit your RPi Serial (found under System info in XBMC) on the RPi store and they will send you a license key. Unfortunately, this is a manual process as indicated by the nice PDF they link you after purchasing the product. A few hours later, I received the real email containing the key.
Installing the key means simply modifying config.txt on the root of your FAT formatted SD card. You can edit it (or create it) by popping the SD card back on to your computer. config.txt seems to be the RPi equivalent of the BIOS. You can control the screen resolution, CPU overclocking, and in this case, entering the MPEG-2 licence key.
The old monitor I was testing with had a weird resolution of 1600×1050, and it wasn’t one of selectable values in XBMC. What I needed to do was add these lines into config.txt. I first tried 1600×1050@75Hz, but then it didn’t work (still stayed on 640×480). Changing to use the 60Hz it seems to accept:
Full list of resolutions here.
After installing MPEG-2, we need to enable Live TV. XBMC 12.0 Frodo has full PVR/Live-TV support for multiple backends including MythTV. To enable it just follow the guide on the XBMC wiki.
After configuration, the MythTV PVR addon should automatically load. If the addon has trouble connecting to MythTV, you will get incessant error notifications. Indexing and fetching recordings happen every time XBMC starts up and seems to take 2 to 3 minutes to complete (I have over 500 recordings). You can’t watch TV while it processes, which is quite annoying. The PVR addon is still in active development, so hopefully this will improve.
Watching Live TV seems alright, although changing channels seems to be slower than MythFrontend. There also seems to be buffering on 1080p streams from time to time and random crashes. Teletext crashes XBMC on the Pi so avoid using that.
One major caveat of the Pi for me was the quality of analogue audio which I’m using to hook up speakers. Apparently is only 11 bit max and definitely sounds noticeably worse than my old laptop. Anybody using HDMI though won’t suffer from this issue. You can apparently use a USB sound card which I’m investigating.
I’m using a HP MCE infrared remote with USB receiver and it works straight out of the box on OpenELEC. Eventually I want to investigate using GPIO ports to have integrated infrared. The reciever units only cost $1. This will be more power-efficient and removes the USB receiver component that’s nearly as big as the RPi. If you have a new TV with HDMI CEC, you can use your TV remote to control the RPi.
For the first few days I found the RPi would randomly freeze/hang in the XBMC menus. It doesn’t respond to the remote, pings or SSH. The lights were still on, but nothing but a hard reset would bring it back to life. The USB charging unit I’m using was old so it probably only supplied 0.5 A, while the recommended minimum was 0.7 A. After changing the power supply to a 0.85 A one, it hasn’t frozen yet.
Live TV show transition issue
I was running MythTV 0.24 and Live TV would stop and the image freeze when it transitions from one show to another. Upgrading Mythbackend to 0.26 fixed this issue.
Audio faster than video issue
When the LiveTV reception gets bad, the video can slow down and go out of sync to the audio. This seems to be isolated to XBMC on the RPi as it doesn’t appear to be happening on the PC XBMC. I haven’t found a solution to this issue. It’s probably hardware acceleration related.
Struggles with some 1080p MPEG2
As mentioned, the RPi seems to struggle with some MPEG2 streams, while it’ll happily play others. Haven’t found any kind of pattern yet.
I’m happy with my RPi purchase despite the caveats. As a MythTV front end, it works, to a certain degree. Even if it won’t last long as a dedicated HTPC, the versatility and good array of inputs will mean it’ll be useful in many other functions.