HTPC Reloaded with Ubuntu 8.10

We have four computers in use at home currently:

  • My Macbook Pro, on Leopard 10.5.5;
  • My wife’s Thinkpad X40 laptop, on Windows XP sp2;
  • My father’s PC, on Windows XP sp2, rarely used;
  • Our HTPC in the living room, on Windows XP sp2;

The Thinkpad X40 was almost 4 years old. I used install Ubuntu 5.04 on it together with XP three years ago, when Ubuntu wasn’t so easy to use as today. My wife is not a big fan of Linux, so she still uses XP.

I’ve been planning to setup the HTPC with Ubuntu for a while, but I’ve heard Ubuntu’s not very happy with the HDMI audio output (I have a Gigabyte GA-MA78GPM-DS2H MB). Finally I decided to give it a try when 8.10 came.

Installing Ubuntu Desktop has never be easier. I had to plug another keyboard as the wireless one couldn’t be used BEFORE the installation. Yes, by before I mean as soon as the installing process began I was able to select language and input username with the wireless mouse & keyboard.

I had a fresh new Ubuntu system less than 20 minutes later. The first thing I did was to change the DPI from 96 to 192 so I could read 3m away from the TV. The cool thing is the external wireless adapter was recognized right after the first login! Under XP I had to install some crazy drivers manually.

All things seemed right. The LG 42” TV displayed 1920*1080. Now the most important part: audio over HDMI.

No sound! That’s expected as so many people had this issue.

aplay -l said the ATI HDMI card was there. So the system recognized it, this was also confirmed by the Volume Control, where I could select HDA ATI HDMI in the Device list. I’ve also turned on the IEC958 (I don’t know what that means), but first I needed to make it show by going to the Preferences below the Device list.

Then I went to System > Preferences > Sound, chose HDA ATI HDMI ATI HDMI (ALSA) in the Sound playback list for Sound Events, hit Test. Still silence only.

Googled, read a lot of forum & blog posts, which I’ve read already before.

Two hours passed, I was tired but not willing to give up. I had the same amount of difficulty to make the HDMI audio work under XP several months ago. This was not rocket science, and I had another half of the weekend to spare.

Then I noticed one thing. I had chosen to activate the ATI/AMD proprietary FGLRX graphics driver, but the progress bar stopped at 0% for a long time and then the window disappeared. I guessed Ubuntu was installing it in the background. Another thing I noticed was there’s a new item called ATI Catalyst Control Center under Applications > Accessories, which I believed was installed by the graphics driver. But when I clicked that, it told me there’s some error in the config.

Rebooted. Logged in. (Wow, the windows effect looked a little different. Thanks to the proprietary driver!) I Opened the Volume Controller, the IEC958 was turned off. I turned it on. Some guy suggested in his blog running the following command to make this change permanent (I don’t remember the post url though, because I couldn’t open it directly and at last I viewed the content via an online proxy):

sudo alsactl store 1

My HDMI sound card was listed as card 1 by aplay -l. I guessed the last “1” in the command was related to this.

Went to System > Preferences > Sound and test the sound again. It’s working!

Putting in a CD, I played several songs for my coming baby. It had been very patient in its mother while I put hard disks, keyboards and other DIY stuffs all around on the floor and made noise and sigh from time to time.

Installed ssh, enabled Remote Desktop. Installed Apache2 & Passenger, MySQL …

Now the HTPC is not only an HTPC, but a media server, local git server, rails test server, download machine. Very cool!