Archive for the ‘HTPC’ Category


Thursday, March 17th, 2011

Had everything running upto XBMC, except hardware video decoding. Tonight I started looking for a solution to fix a missing library figuring that could mean something. Installing xvba-va-driver thinking all would be good. Next thing I know the system has no working X setup anymore. Xorg config has not changed judging by it’s timestamp and yet X just won’t work anymore… All I can think of now is a Dutch word: kutzooi!

Let there be music

Wednesday, March 9th, 2011

Woohoo, finally got sound :D As usual it took a lot of reading up and fiddling around, while in the end it all seems so simple. In short I did the following things; first make sure the Xonar DX card is the first device instead of HDMI audio, then figure out the needed device configuration and unmute channels.

Switching device order was trial and error, but eventually it worked. In the end all that was needed was append the following line to /etc/modprobe.d/alsa-base.conf

options snd-hda-intel index=1

This moves HDMI audio output from 1st to 2nd place enabling the Xonar card to take the first place. Initially I also added  line for the Xonar (snd-virtuoso), but this resulted in an error message during boot (cannot find the slot for index 0 (range 0-0, failed with error -16). No idea why, but it’s not mandatory, so remove and problem solved.

Next was figuring out the exact configuration that produced sound. I’ll spare you the details, but what eventually worked was this:

  • hw:0,0
  • default mixer (not driver default, this produces invalid CTL errors)
  • line or master channel

By now I had the side and back channels working. Front channel was silent. Double checked if all channels had enough volume and were unmuted with alsamixer. All set but no sound. Running out of ideas I just muted and unmuted the card (you could see the ascii-art switch colour) and voila, sound on all channels. Must have been a glitch that the front channel wasn’t working in the beginning. Haven’t had a silent channel ever since, even after reboots (and switching on/off side and back channels work fine). Haven’t tried S/PDIF yet, but for the moment I’m assuming it will work now that analog output is working.

Audio and video troubles

Monday, March 7th, 2011

Last entry of this weekend and just need to blow of some steam. Been trying to get Alsa audio to work and well, what a mess! One audio device, no problem, but with multiple devices the trouble starts. If you have this Alsa version, do that. If you have that distro, change it to this. Using udev? Your loading order can get scrambled and you need to change that config there. New version? Don’t use snd_ prefix in that case. On that distro, you config is located there, and if not, look over there. Linux/Alsa devs, I’ve got 1 thing to say to you; W….T….F….?!

Also not working is hardware video decoding. As expected ATI cards are a pain. 2D, no problem, got that working. But decoding is a different story. Need to get VA-API running/compiling, which in turn is a wrapper for XvBA which is a wrapper(?) to get to the UVD2 engine. Or something like that? Installing libva-dev has no effect when compiling MPlayer, e.g. configure still thinks the VA dev stuff is missing. No idea why, but haven’t spend much time on this yet. Want to get audio working first because listening to some music has a soothing effect in situations like this ;)

Limit found

Sunday, March 6th, 2011

Hmmm, it seems I’ve crossed a limit in the current setup. Just gave it a 1080p x264 video @10Mbps with DTS 5.1 96 kHz/24 bit @1.5Mbps to chew on. 100% CPU usage and slowed down playback. Still no sound, so the DTS stream might not even play a role. My guess is hardware decoding is not used by mplayer and/or fglrx driver. Let’s call it a challenge =)

Some early and completely unscientific numbers

Saturday, March 5th, 2011

A quicky with some numbers. Keep in mind nothing is optimised yet. All software is generic 686 32-bit, not amd64. The RAID5 array is up and running with 5.5TB of space ready to be filled (still have 1 2TB drive doing nothing). Copying files via NFS from the old seedbox to the new server peaks at around 66MB/s. When peaked, CPU usage is around 30% for one core and 80% on the other. While it’s copying, power usage hovers around 70W.

Note that above numbers were done on an extremely scientific basis. Mount the NFS share, start copying with Midnight Commander and watch a movie while keeping an eye on the server ;)

There is an issue however. I still haven’t managed to get audio working. Alsa is a pain when it comes to multiple audio devices and in this case the HDMI and Xonar devices are batteling eachother. On a positive note, 720p video plays great, but again no sound.

To be continued…

Making progress

Saturday, March 5th, 2011

If the MicroServer were human and female, I’d be in love. The little thing is fantastic. Got Debian testing and Fluxbox running out of the box, the RAID5 array is rebuilding in the background and slowly working through all steps. Even ATI’s proprietary driver install went relatively smooth (once you figure out it needs kernel headers). ATI’s installscript logs things in /usr/share/ati/ and only there. According to the GUI nothing is wrong and the entire install went fine. Which of course isn’t the case. Apart from this annoyance, it went remarkably well.

One of my worries was the temperature of the passively cooled vga card. So far things appear to be within limits. Last night it stabilised around 62.5 °C and during the night it went down to 52 °C (signal off and central heating turned down). This morning it has risen to 59.5 °C while typing this. This doesn’t give a complete yet, since I still need to test 1080p movie playback.

To get each temperature reading I used the aticonfig tool:

aticonfig –odgt

Stuffed server

Thursday, March 3rd, 2011

Just a quick look at the new server now that everything has arrived. The thing is almost ridiculously small :D But then again it’s stuffed with only some room left in the CD-ROM bay.

All SATA bays are filled, both RAM slots are filled and the VGA and audio cards are there. In some places thing are separated by mere millimeters.

Just did a quick boot and the good news is Debian testing boots from USB (plugged into the internal USB connector). Things didn’t explode, but so far networking does not work. That’s my next order of business! Until then, enjoy the nice photo on the left ;)

Should ATI still burn in hell? Very likely so!

Sunday, February 27th, 2011

There’s probably a week’s worth of ranting about ATI’s and NVIDIA’s proprietary gfx card drivers, but for now I’m keeping it short. A short introduction is in order. Years ago I knew exactly which card was needed to get the best performance. It took time reading up and keeping up-to-date with all the latest developments. Since then my interests changed from knowing the exact details to something along these lines: I don’t care how it works as long as it works as you can reasonably expect (and I expect a lot by default. If you can’t deliver a decent piece of hardware, software or service, please do the world a favor and burn down your company as quickly as you can. Stopping myself here, as this is also one of those subjects I can go on about for days).

Anywaaaay… all those years ago I bought ATI gfx cards for the simple reason that they were the fastest. Not that you’d ever notice this in a real life usage, but synthetic benchmarks ruled. But as you know a decent piece of hardware is only half the story. So imagine you’ve got this sexy (the nerdy kind of sexy, not the erotic variant) piece of hardware lying in front of you, you wipe the drool of you chin, you plug it in and boot the latest Linux kernel. Next is installing ATI’s latest driver only to discover you’ve ended up in hell. It may have been years ago, but my mind still bears the scars of agony and frustration… hours on end. For this alone ATI deserves to burn in hell for all eternity (which is a pretty pointless thought if you don’t believe in heaven and hell (but the creation of an artificial hell would be most welcome. We could stuff all those greedy corporate bastards there. Maybe even a webcam and some running man style show for our entertainment to watch (which in turn we would watch via networks run by the same corporate bastards and thus negating the entire idea… anywaaaaay :)))).

Long story short I swore never to use ATI again. Since that time I’ve switched to NVIDIA on systems that required high performance 3D and embedded Intel for everything else. While NVIDIA cards also come with a proprietary driver, their installation process was (or is) much less frustrating. Intel on the other hand sucks for 3D, but just works for everything else. For non-gaming purposes, Intel is a blessing and I can highly recommend it if you don’t want to fiddle around. Now fast forward to 2 weeks ago when I ordered the MicroServer. Never thought of the ATI horror and focused on a card that fit and satisfies the max power limitation (25W for the PCIe x16 slot). And from what I’ve read ATI’s Linux support is still something to cry about. Don’t care about 3D, but for HTPC usage hardware decoding support is more or less mandatory.

So when all components have arrived I’ll be attempting to get a Radeon HD 5450 GPU up and running. This GPU has an UVD2 video engine (UVD = Unified Video Decoder) and uses the XvBA (X-Video Bitstream Acceleration) API. The UVD 2 engine features full bitstream decoding of H.264/MPEG-4 AVC, VC-1 and MPEG2 video streams. If rumours are correct it sucks balls compared to NVIDIA’s Video Decode and Presentation API for Unix (VDPAU). Rumour also has it that this proprietary crap has to do with DRM. Just as you think your hatred of a certain technology can’t get any deeper, it does. In any case I’m already preparing for some torture and if all else fails I’m just gonna get a GeForce G 210 or GT 220 card (only realistic options considering the 25W PCIe limitation).

Btw, anyone else thinks writing your entire company name in capital letters makes you think of sad 16 year olds screaming for attention on the net?


Saturday, February 26th, 2011

Just realised I never wrote about the whole server thing is for. Silly me! I like watching movies and series and listening to music, preferably in the best quality available (e.g. full hd and lossless). With movies @10GB a piece, series @1.3GB per episode (and going on for several seasons), this takes up a lot of storage.

Currently I use 3 systems – a big noisy power sucking 19″ rack for storage, a silent mini-ITX for torrenting and a Popcornhour for playback. Why replace this setup? The first is pretty obvious, so I’m going into that. The Popcornhour was chosen because I don’t want to fool around with codecs and GUI software. Select whatever you want to play and press play. The mini-ITX sits in the middle and downloads/seeds 24/7 while the 19″ rack is powered down. Every once in a while it’s 1TB harddisk is full and stuff is transfered to the big server (or the other way around if I want to watch something stored on the server). Besides HTPC purposes the setup is used for backups, storing projects, photo’s and so on.

What the new server must do is replace all 3 systems mentioned above. It must be able to run silently 24/7 without using too much power. It must be able to play full HD and play music (hence the gfx and audio cards) . And it must have a shitload of storage to keep safe and accessable. 10TB might seem much, but my guess is I’ll run out of space within a year.

Delays and the search for decent audio

Saturday, February 26th, 2011

As you might have guessed by the non existing happy post earlier this week the ProLiant MicroServer project has suffered some setbacks.  All components were in stock and the payment was made. Here the trouble began. A bank transfer which should have cleared within an hour took almost a week to clear. By now the server itself was no longer in stock and I’m currently still waiting for it. Harddisks, memory and gfx are en route and should arrive today. But without a server to connect it all to, there’s not much happening.

On top of that my plans for cheap  S/PDIF out were also foiled. Had my sight set on a Terratec Aureon dual USB stick. Analog sound would be pretty poor, but it came with an optical adapter which offered possibilities. Hooking it up to my amplifier means the amplifier’s DAC is used (which is by far superior to the cheap stick). Order placed and again payment troubles… sigh… This time a DDoS attack aimed at my bank. Over a day later the bank was back online, but the price of the Terratec stick had gone up 35% (WTF!?). And due to Mycom’s crappy ordering system you have to order again if payment fails. Well done Mycom, you’ve lost a customer.

However in a way this was a good development. I did some reading in the meantime and for some reason the Terratec stick doesn’t only offer analog stereo sound, but they also limited digital output to stereo. One of the requirements for the new server is that it must have pass-through S/PDIF for AC3, DTS, etc. So the Terratec was out. In Terratec’s defense, they mention this limitation in the specs. It’s just that I never expected this. What idiot limits digital output to stereo only?!

So what’s next? USB-wise I haven’t found a decent solution yet. No matter what, cost goes up. There are cheap low quality brands that I swore never to buy (might as well flush your money down the toilet). Another big name is Creative, which I also swore never to buy again (I’d rather chew off my arm). All USB things considered, this was quickly going nowhere…

A nicer, but more expensive solution would be to use an internal cards. The server has a PCIe x1 and a PCIe x16 slot. The x16 slot is taken by the gfx card leaving the x1 slot free for a low-profile card. Since my desktop PC already has an Asus Xonar DX which fits all requirements, I think that one’s the ideal candidate for trying. Considering it’s designed for proper analog output, it’s overkill for just S/PDIF usage. But given the choice between a cheap and crappy card or this one, I’d rather spend a bit more on a decent card that has a future beyond digital out. Besides, try finding a card that is low-profile and PCIe (very limited choice!). Whether it fits or not remains to be seen. It’s not the shortest card and it needs additional power, but we’ll see :)

Oh and in case you’re wondering why not use the HDMI output of the gfx card; HDMI is not an option. MY amplifier doesn’t have HDMI. Now I could route audio through the TV (HDMI in, S/PDIF out), but that introduces a very annoying delay between video and audio. I blame my Samsung TV for that as it has other troubles as well (as in not properly detecting the signal of a Popcornhour mediaplayer).