Thursday, February 01, 2007

DIY - Home Theatre PC (HTPC)

Introduction


I recently built, configured and installed a PC into the lounge, to function as my entertainment hub. So many people have asked me what is involved in doing it themselves so I thought I'd write down what I learnt.


Hopefully this article will not be too technical, but it may be a difficult goal given the subject matter.

What is a HTPC?

If you've seen mine, then you already know - if not, the HTPC is a PC designed for the lounge, acting as the media hub of the house. It can record scheduled TV (Free-To-Air) whilst playing movies (or other recordings), listening to music or even while you're out. All interaction is via a remote control, much like using a DVD player. Other features include photo album viewing, checking the weather and watching downloaded movies (eg Torrents)

Get Your Facts Right

There is so much information on the web about the HTPC that you can't possibly start without reading as much as you possibly can about what to expect. Even with my 10 years within the IT industry (as a programmer, so not a techie) I still read article after article for 3 months in order to fully understand what would be required - and I still missed some things!

It was important for me to find good reliable reading material from an Australian perspective, so my first stop was to join (and remain) a member of xpmediacenter which has been extremely beneficial in every way. Before buying anything, get online, read and ask what others have used for various hardware concerns. Not doing this early enough cost me quite a bit!

Define Your Requirements

The most import requirement is budget. This will define the entire project and will ensure you are satisfied with the outcome. The other important requirements have to do with functionality, capacity, and aesthetics.

Personally, my requirement was to limit myself to AU$2500, able to display HD video and playback HD audio to provide total 'front end' capability to the 42" HD plasma TV and 5.1/DTS Sound System, and with the capacity to record and play TV concurrently.

If I'd known then what I know now, I'd say it's extremely important to consider heat (i.e. noise and ventilation) as well as the above 'features'. The sound of an overworked CPU fan will ruin the quiet scenes in any movie!

Be Prepared for Problems

You may never encounter any, but it is possible - If you are building the box, or even just configuring the software, you will inevitably have issues - mostly they will be simple, such as installing a driver or a codec, or they might be more complex and require some experimentation or even outside help. The best thing you can do is ensure that everything has been configured, and tested, prior to demonstrating to family and friends! I actually had mine in the study for over a month as I ironed out all the problems (it turned out that the original DVICo TV card was a dud!)

What You Will Need

The core hardware components that your HTPC will need are:
  • TV Tuner card (Analog or Digital) - more likely you will want at least 2 - so you can record and watch two stations concurrently - the current version of MCE only allows 2 cards to be installed without resorting to registry hacks

  • Quality Audio card (on board will do) - If you intent to play music, or watch DVDs via your AV Receiver system, you will want a coax / spdif capable sound card

  • Graphics card with digital (or HD digital) output, or analogue output, depending on your TV - personally, I wouldn't touch analogue, since it is being phased out within the next few years. Also, 3D Gaming features are not required, and will probably cause problems due to heat so these types of cards should be avoided if possible. If you wish to route the video to yuor TV via the receiver, you will need to ensure that the AV catoers for the cable type that the TV supports - for this reason, I have implemented my solution using Component Video, even though the TV does support HDMI.

  • Hard drive - get the largest, fastest, quietest one you can afford (get two!). This will be used a lot so don't skimp here. Recording HD TV will 'cost' 4Gb/hr, so you will need plenty if you plan on keeping all your favourite shows on the machine. I bought a 320Gb drive and have almost filled it up, only 3 months into operation.. If you have a lot of music, a second drive for music and AVIs might be a good idea, since MCE only allows one HDD to be indicated for storing TV recordings.

  • Internet via Network card / Wireless card - Although not essential, not having the Internet on hand will severely handicap your system.. (Dial up is probably not going to cut it). If you wish to stream HD over wireless then you must get the latest 802.11g or 802.11n standard which supports high data transfer rates.
And, optional features include:
  • AV Receiver style case - with LCD or VFD display (VFD is what Receivers generally use, as it is brighter but uses less power), and front USB, Firewire, etc ports for convenient access

  • Remote Control device - the MS one comes with a keyboard as well..

  • Wireless keyboard / mouse - you probably won't use them that much, but can be handy for surfing the net, or searching for a stored track or video! (You will need to consider where they will reside - mine is on the bottom shelf of the coffee table

  • Silent / Quiet operation - generally, this will require either silent pipe technology, or passive cooling - this approach can be a bit risky if the air flow within and around the case is hampered, but you will thank yourself when this is all working right.

Putting the Bits in the Box

Although I have considerable experience with building PCs, I chose to use a hardware supplier to build and deliver the final product - I didn't have the time, nor did I want the issues that often arise due to hardware installation problems - still, this can be a rewarding part of the project, so it's a matter of choice.

Depending on who you use, they might even setup and configure Media Center for you.

Its Nothing Without Software

Although MS has just released Vista, I implemented my solution of Windows Media Center Edition (MCE), which is a hybrid of XP Home and Pro, with the Media Center functionality bundled in. The best feature of MCE is that all hardware you buy will be designed to 'Just Work' with it. It should be a breeze to get MCE to find and configure all the necessary bits and pieces. This was the case for me and others I've spoken to so far..

There are several alternatives to using Windows and MCE, which might be considered. You could choose a Windows based commercial package, or use the open source Media Portal, or you could go MS-free completely by choosing a Linux implemenation, such as MythTV. Although these solutions have lots going for them, I chose MS MCE since it is the most well known, and as such, most if not all hardware simply 'Just Works' with it.

There are a few things that you will need manual configure after MCE is installed:
  • Electronic Program Guide - Although in the US this 'Just Works', in Australia, it's a different story. Apparently, due to legal problems with the TV stations here, the guide is not published.. You will need to install Blade Runnner Pro (BRP) and every week will need to run it (from MCE) and manually import the listings into MCE (from the TV Settings menu) - slightly annoying, but not the end of the world. BRP requires an account with a homebrew TV listings website called OzTivo (maintained by users!) to work, but this is easily configured.. You can even add to it if you like

  • AnyDVD - Necessary to overcome the region restrictions technology that Media Center enforces. Not free, but I'm sure you can afford it!

  • Codecs - every media format requires one, and unfortunately they don't all come with Windows, or MCE. Codecs are required for both encoding (burning, converting) and decoding (viewing) so they are essential. Different codecs provide different quality and performance, and so in general, shop around!

    There are a few collections of decent codecs called K-Lite, or ffdshow (don't know about much about this one) to name a few that include most of the usual decoders you will require. In theory, if a file you wish to watch or listen to doesn't work, try it in Media Player (MP) since MCE uses this as it's display engine (if it works in MP, it should work in MCE). MP will notify you what the missing codec is or perhaps, if it's well known, it may even download it for you.

    Video codecs for decoding the stream coming from the TV tuner will require a decoder that will probably come with your new DVD player (if not, you'll have to buy it) such as CyberDVD or PowerDVD or one supplied with your graphics card (ie from NVidia).

  • Some DVD Burning software - not sure which one is best.. This is still on my to do list. Such a feature should have come 'out of the box' with MCE, such that you can burn recorded TV to a DVD.. It appears that you require an MPEG-2 encoder such as one from Sonic (publisher: Roxio?) to do this.

Outstanding Issues

  • Noise - I still need to replace my fan that makes too much noise. It is not the constant whirling noise that one would expect however, I could probably get used to that - Instead, it is a constantly changing high (not piercing though) pitch that sounds like the fan is off-balanced. I am looking at a cooling tower (like the Noctua NH-U12F CPU Heatsink with 120mm fan)

  • TV Recording archival - Burning to DVD and converting to MPEG4 (DivX, Xvid). I'm sure that it is quite possible to convert the TV recordings, however these features are not a part of the basic MCE install. I have looked at several alternatives, however at this stage nothing has stood out as being the perfect solution. A solution I will explore when time permits is MyTV ToGo, however I don't have any good information on it at this stage

  • Scheduled recordings from Standby - I have nto yet worked out how to reliably start MCE from standby automatically (ie when a show that I want to see is on) without doing it myself. This solution would involve reliably starting and returning to standby in time to record any shows I would like.. I have found a free tool called MCE Standby Tool which might do the trick though.

    From what I've read, it appears that MCE will start from standby correctly to start recording from the schedule, however in my case, it appears that either Windows or some drivers don't like restarting MCE after standby - I generally have to reboot after doing it as I have find that I have no valid TV tuner cards afterwards. Apparently MCE will fix this but I don't know yet..

  • Finding out more about the Registry Hacks required in order to have more tuner cards. 2 more should do the trick!

  • Vista - There are several early adopters of Vista (Premium and Ultimate include MCE) however I am yet to attempt it myself - when time permits I will create a new partition and have a play..

Some Further Reading
I wish I knew about these ones before I built!
Products I recommend and use
Good Luck!

If you're still reading this, you can see now that building and running a HTPC is not a casual affair - like most things to do with computers, and in particular with cutting edge technology, there is a lot to consider, and a lot to learn. Luckily there are a lot of knowledgeable people at the various forums who are willing and able to help out.

As you can see, I still have an outstanding list myself, but these features are not essential for my needs at this point. Hopefully I will solve these issue soon and will provide an update.

If you are still willing to undertake this project then I think you will be very happy with the final result. I know I am, and even my once-sceptical girlfriend is now a convert.

All the best.