MythTV is
cool. Really cool.
But unlike many other Linux applications, you can't just stick an
install
disk in the old '486 in the closet and have it fill a need.
MythTV
takes hardware -- good hardware. I decided that if I was ever
going to build a MythTV box, it had to basically do it all. I
already have a TiVo, so simply reproducing TiVo's capability made no
sense to me. It also had to look like home theater
equipment. With these thoughts in mind,
I started spec'ing out
hardware: Dual Tuners, Motherboard with surround
sound,
Silverstone case... I quickly passed $1300 for a cost estimate, and the
project went on hold. Then came a deal I couldn't --
Uhhh, well I guess I could have passed up, but I
didn't.
CompUSA had the HP z555 Media Center PC on closeout. Here was
great hardware, already built into a beautiful case -- for less
than it would have cost me to build.

HP's z555 ships with Windows Media Center. Will it run
Linux/MythTV?
Photo: HP. Used for educational purposes.
The system ships with WindowsXP/Media Center. Would it run
Linux? Would Linux support the z555's hardware? I
took
the gamble, and I have to say that while I do not currently have every
feature fully supported, the system is functional as a very nice PVR .
UPDATE:
I have now gotten
much more working, and I believe that I can now say that the system is
more functional (at least for my needs) than it would be with Windows
Media Center on it.
Why MythTV?:
Why not just leave Windows Media
Center? The purpose of this page is not to discuss Windows vs.
Linux. I am a "Linux Person" and I wanted my PVR to have UNIX
functionality.
For example, the ability to automatically run scripts to re-encode what
I have recorded.
About This Document:
First and foremost, this document is NOT A HOW-TO. Instead,
this
document
describes some of the z555's hardware, and what I had to do to get it
to work under Linux (Fedora Core 4, specifically.) Various parts of
this document are also applicable to other z55x - series boxes, such as
the
z540,
z545, z552,
z553, z555, and z557. (OK, OK, I admit it - listing them like
that is just search engine bait.) I
will not give step-by-step instructions in this document. If
I
say for example:
"Change the permissions on this so that a regular user can write to
it." I expect you know how to do that. This is NOT
Linux
101. Secondly, most of what is here is actually from other
people's work. I relied heavily on the
"Fedora
Myth(TV)ology" site.
I am not going to reproduce Jarod Wilson's instructions.
Rather I
am going to assume that you follow his (excellent) instructions, and
reference this page for the specifics of the HP z555.
Most importantly, I am still getting things to work on this
box. This page will be updated as I learn
more. If you can provide input, or you have a (relevant)
comment, email me at:

(Sorry
for the obfuscation, but there is just too much harvesting going
on.)
The above email address no longer works, instead, please
Discuss this article on the
Linuxslate
Forums.
Disclaimer:
THIS DOCUMENT IS PROVIDED BY THE AUTHOR "AS IS". IN NO EVENT
SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS DOCUMENT, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
More Philosophy -- Why Fedora Core 4?:
The Fedora Project represents the cutting edge (but perhaps not
bleeding edge) of Linux. Due to the hardware on this box, you
need pretty close to the newest drivers for many things. Your
Debian Woody disks
aren't going to help you much. What is detailed below does
contain proprietary code. Also, unlike the "Fedora
Myth(TV)ology"
site, I use a combination of RPMS and building from source.
If
you are afraid of typing
'make'
please DON'T read on.
OK enough talk, lets look at each particular aspect of the
hardware and
what it takes to get it running under Linux:
Basic Hardware, and the Fedora Core 4
Install:
The basic hardware is a Pentium 4 @3.0GHz supported by an Intel Chipset.
There is a single 7200 RPM 250G HD connected via SATA, and a
LightScribe CD-R/RW DVD±R Drive connected via PATA
(IDE).
LightScribe is only supported in Windows, but who spends an hour
designing a graphic for every TV show they burn to disk anyway?
Before beginning the install, go into the BIOS (F1) and Set
the
PATA/SATA setting from Enhanced to Combined.
NOTE: This is only done for the install. After the
install,
set this back to Enhanced, or the DVD/CD Drive will have no
DMA.
This will result in DVD frame dropping, and the inability to burn DVD's.
It does not take long for the difficulties to show
up. When
you attempt to boot the Fedora Disk 1, you'll get an error about
mounting the root filesystem, and a kernel panic. The almost
unbelievably silly workaround is to
type some nonsense at the boot prompt. This will return an
error,
and another boot prompt. Just enter a valid boot option at
this
second prompt, and all will be fine:
The
'nofb' and 'text' are needed if you
are connected to a TV (s-video or composite) for the
install. If you are connected to a Monitor, go ahead
and
try a GUI install.
I recommend sticking pretty close to the suggestions on the "
Fedora
Myth(TV)ology" site for configuring your disks with one
exception;
I used /var/video as the mount point for the MythTV video storage
partition.
I split from Jarod Wilson's recommendations in another way
too... I
used
Gnome.
Follow Wilson's package options, and make sure you install
all
relevant development stuff. (X, Gnome, Legacy).
After the install, reboot and catch the machine at the grub
boot
screen. Hit 'a' to add options, and then append '
single' to the
end
of the kernel parameters. This will prevent the system from
trying to start X, and drop you to a single user shell. From
here, follow
the directions below to install the nVidia drivers.
When this is done, reboot, and go through the RedHat
Firstboot. Don't
forget to create the mythtv user.
Now that the system is up, we need to let it go out and do an
update.
Obviously, this requires a network connection. See below to get either
the WiFi or Ethernet
connection working. Then, in a terminal do:
Since
the update will affect the kernel, and X, we will have to repeat
the installation of the nVidia drivers and possibly the networking
drivers.
Wireless Keyboard:
Identified as: BTC USB Multimedia Cordless Kit.
This is handled in hardware on the z555, and is recognized as a
standard 105 key keyboard. It can be used in the BIOS and in
the
install. The "Multimedia" keys along the top also produce
standard key codes. I have not done it yet, but
xmodmap should
allow you to map
them as desired.
nVidia GeForce6600 Video:
Go to:
http://www.nvidia.com/object/unix.html
and download the Latest Linux IA32 drivers. I found it worked
great to put them on a flash card transfer to the z555. Prior
to
the first actual boot, copy the
NVIDIA-Linux-x86-1.0-8178-pkg1.run
file
to the HD, and run the installer. The 1st attempt will fail,
and
it will ask you if you would like it to attempt to download a driver
for your kernel. Well, you can try if you want, but since we
haven't done the network stuff yet, it is not going to work.
Select
No,
or let it fail, and
it will inform your that it is attempting to build a module for your
kernel. As long as you installed the development packages,
this
should succeed. Let it install the module, and
reboot. You
should be greeted with the nVidia logo when X starts.
Network -- Wireless:
The z555 contains a PCI 802.11b/g WLAN card identified as:
Intersil ISL3890 [Prism GT/Prism Duette]. After spending a
day
trying to get the Prism54 drivers working, I finally gathered from the
Prism54.org forum
that there are
2 versions of this card. Apparently, the z555 has the version
that is not supported by the old (FullMAC) drivers, and probably not
really working with the new (FreeMAC) drivers either. I
resorted
to ndiswrapper, and was up and pinging in minutes. Here's the
steps:
rpmbuild -ta ndiswrapper-1.7.tar.gz
- This will place 3 ndiswrapper RPM's in
/usr/src/redhat/RPMS/i386
kernel-module-ndiswrapper-2.6.xx-x.xxxx_FC4smp-1.7-1.i386.rpm
ndiswrapper-1.7-1.i386.rpm
ndiswrapper-debuginfo-1.7-1.i386.rpm
- Install them. I guess you
don't really need the debuginfo one.
- Apparently, the card is the same as an
SMC Medalion
MD41300. Obtain the Windows drivers from here.
- You should see at least the following
files:
2802W51.sys 2802W.cat 2802W.inf
- In the directory with these files, do:
ndiswrapper -i 2802W.inf
Check it with
ndiswrapper -l
This should indicate:
2802W driver present, hardware present
modprobe -r prism54
depmod -a
ndiswrapper -m
modprobe ndiswrapper
- Check /etc/modprobe.conf It
should contain a line:
alias wlan0 ndiswrapper
- If it isn't there, add it.
- Prevent
the system from loading the prism54 modules by doing:
echo prism54 >> /etc/hotplug/blacklist
- You should now have a wlan0. You can
configure this
interface in the regular RedHat GUI Network utility (or from the
command line with iwconfig, and ifconfig, if you would like).
- Test the interface by pinging somebody.
- NOTE:
If you change to a different kernel, you will need to
re-do these steps starting with the rpmbuild.
Network -- Wired Ethernet:
The Ethernet port is identified as: Marvell Technology Group
Ltd.
88E8053 Gigabit Ethernet Controller (rev 19).
Due to the location of my system, I am not using the Ethernet
port. Drivers are reportedly in new kernels (But not the
original
Fedora Core 4 2.6.11 kernel). A driver can also be downloaded
from:
http://www.syskonnect.de/syskonnect/support/driver/htm/sk9elin.htm
Audio:
The Sound Sub-sysem is identified as: Intel Corporation
82801FB/FBM/FR/FW/FRW (ICH6 Family) High Definition Audio Controller
(rev 03)
Apparently, there are bugs in some versions of Alsa that can cause
problems (No Sound) with this card. I tried the 1.0.11rc2
build,
and with some difficulty, it worked - including Surround Sound through
the S/PDIF connectors - Coax and Optical. Ready?
Let's hit
it:
- Remove the current
version of Alsa. Of course you'll need to --nodeps these:
rpm -e --nodeps alsa-lib
rpm -e --nodeps alsa-utils
rpm -e --nodeps alsa-lib-devel
- Reference the
entry for Intel HDA on the Alsa-project site for more
details.
- Add/Fix lines in
/etc/modprobe.conf. Here's the relevant
section of my /etc/modprobe.conf
# ALSA portion
alias char-major-116 snd
alias snd-card-0 snd-hda-intel model=6stack-digout
alias sound-slot-0 snd-hda-intel
# OSS/Free portion
alias char-major-14 soundcore
# card #1
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss
- I am not sure why, but it seems I had to create
the group
'audio'. I did this via the User Configuration GUI, and added
root and the mythtv user to this group. Help here
if you
need it.
If you have to do this, there was probably either a problem in the
initial FC 4 install, or in the installation of alsa.
- Start the sound server (if not already running), and insure
that
it always starts at this run level:
/etc/init.d/alsasound start
chkconfig alsasound on
- Heed the warnings about all channels being muted
after the
install. Run alsamixer, and unmute/set volumes as you wish.
If
you are using the digital (S/PDIF)output, don't forget to unmute it.
This option may not be shown by default in some mixer apps.
- OK - here's the part that caused me quite a bit of lost
time. The .asoundrc or asound.conf file. I have no
clue
about this file, so please don't ask. Mine is a *Very* slight
adaption of the one on the Fedora
Myth(TV)ology site. I simply changed the name of
the card in
the comments, and changed the device for the digital out portion of the
card from 0 to 1 (one occurace.) Grab
mine from here. Note that I have only the
/etc/asound.conf
file, and none in the mythtv user's directory.
- Now
test both the analog and S/PDIF outputs with aplay:
aplay -D analog /usr/share/sounds/startup3.wav
aplay -D spdif /usr/share/sounds/startup3.wav
- To make sure that the RedHat sound card detection
program is not
run, remove it. You can --nodeps it or remove Firstboot too.
rpm -e --nodeps system-config-soundcard
- In MythTV, add the following to the DVD Settings:
-ao alsa -ac hwac3,
(Note the comma on the
end.)
Most sites say the above shoud be:
-ao alsa:device=digital -ac hwac3,
or
-ao alsa:device=spdif -ac hwac3,
For me, these just
produced noise.
- You will also want to turn on "Enable
AC3 to SPDIF Passthrough"
in
Settings >> General.
- With the
above, Music Playback (Mythmusic) does not use the
digital outputs. Music playback can (theoretically) be made
to
use the digital outputs via the adsp device. If I
get this
working I will post more info here. UPDATE: TV and
Music
Playback via S/PDIF now seem to work for me just by
selecting /dev/adsp in the relevant setup
sections. I did
not
add any options line having to do with OSS emulation and the adsp
device to modprobe.conf. I did have to set the permissions on
/dev/adsp This may need to be put in
/etc/rc.d/rc.local so that it happens every boot.
chmod 666 /dev/adsp
- Troubleshooting
- /etc/init.d/alsasound
restart is your friend.
- Check
the mixer settings. Check them again after you do
the above. Check them again after you think about doing the above.
It seems that alsa likes to use any excuse at all to mute everything.
- Check your audio systems' settings.
- Try
restarting whatever it was that you are trying to
play. I have on occassion changed no settings at all, and it
has
started to work when it was not previously. Either alsa is
not
setting something correctly, it is an idiosyncrasy of the z555
hardware, or an idiosyncrasy of my reciever.
Dual NTSC Tuner Card:
The 2 tuner NTSC
card is a Hauppauge WinTV-PVR-500 MCE with the backplate (and IR
port??) removed.
The card has MPEG encoding hardware for each tuner. This is supported
by the ivtv project. This one is
straight-forward. I choose to build from source, but unlike
sound, we can use the stable release here. We can follow the
ivtv
instructions pretty much straight through.
UPDATE: As of this writing, The RPM's for
ivtv should
work. If you would rather use the RPM's, follow the
instrcutions
on the
"Fedora
Myth(TV)ology"
site with the following changes:
- Install the proper kmdl for your kernel
version. As of this
writing it is ivtv-kmdl-2.6.14-1.1656_FC4smp.i686
- Also
install the audio firmware: ivtv-firmware-audio.noarch
- Do not add anything to /etc/modprobe.conf
Frankly, it is really not much harder to build from
source. If
you choose this method, continue below.
- Download ivtv from: http://ivtvdriver.org/index.php/Main_Page
As of this writing stable was 0.4.2
- Unpackage it
someplace where you can build it.
- Follow the
instructions (top to bottom) on the How-To page to
build and install ivtv.
- Don't forget the firmware
section. NOTE:
You
need the encoder and audio firmware, but not the decoder. In
addition, I suggest making symlinks, and not renaming the firmware
files. .
- At this point, /lib/firmware/
looks like this:
-r--r--r-- 1 root root 376836 Jan 7 23:25 HcwFalcn.rom
-r--r--r-- 1 root root 14264 Jan 7 23:25 HcwMakoA.ROM
lrwxrwxrwx 1 root root 12 Jan 7 23:28 v4l-cx2341x-enc.fw -> HcwFalcn.rom
lrwxrwxrwx 1 root root 12 Jan 7 23:28 v4l-cx25840.fw -> HcwMakoA.ROM
- An easier way to test it is to just run gmplayer,
choose Open
File, select all files, and navigate to /dev/video0. You
should
see live TV. you can change channels with itvt-tune -c <channel
number>. Similarly, the other tuner should be on
/dev/video1. The FM radio works too. FM radio apps
for
Linux are beyond the scope of this article.
ATSC Tuner Card:
The ATSC tuner card is a modified ATI HDTV
Wonder
card. It is modified in the sense that (as with
the NTSC card) the backplate is removed. Additionally, all of the
connectors other than the ATSC RF connector are
absent. The
ATI HDTV Wonder is listed as supported by
the
Linux
DVB
drivers.
(Click ATSC), but the 2.6.14 kernels do not recognize this
card.
With the release of the 2.6.15 kernel, this HDTV capture card is
supported. Details can be found at the
MythTV
Wiki.
Note that the
ivtv
How-To has
instructions for systems with mixed ivtv and DVB cards.
The card cannot currently
be used
as a 3rd NTSC tuner. Only the digital portion is currently
supported. Since I don't have a OTA (over the
air) antenna
right now, I have not tried this myself. When I do, I will
post
details of my experience.
The Remote, and IR control:
The IR Subsystem is identified as: Tatung eHome Infrared
Transceiver. USB Vendor code 1460 ProdID 9150
Note: I am not currently using this to control a cable
box. That should work, but is untested.
The IR subsystem is supported by recent versions of lirc.
Instructions for the
impatient: Use the lirc_mceusb2 module. For more
detailed
instructions, read on:
- NOTE: Depending on your kernel version,
the RPM's for lirc
may work. Just follow the "Fedora
Myth(TV)ology"
site instructions for installing lirc, with the changes
noted
below.
- To install from source, first remove any
RPM's related to
lirc. If you have already
installed Myth, lirc is part of that install. We need to
remove
them. I just used an 'rpm -e --nodeps', but this may cause
problems with
future yum updates. lirc needs to be added to the list of
things
not to update otherwise it will overwrite what we install from
source. (Correct instructions for this appreciated).
- Updated:
The 0.8.0
Releases should work fine. Grab the latest version
from: http://lirc.sourceforge.net/software/snapshots/
- Unpackage it in a convenient directory, and run setup.sh
- Choose "Driver configuration" --> "USB
devices"
-->
"Windows Media Center Remotes (new version, Phillips et al.)"
- Choose "Software configuration", and verify that only the
first
option (Compile tools for X-Windows) is selected.
- Choose
"Save configuration and run configure".
- Do make, then make install.
---> Continue here if you installed lirc via RPM's.
- Add the following to /etc/modprobe.conf
alias char-major-61 lirc_mceusb2
- Perform the following copies/links of items that
are
distributions specific (and/or MythTV specific), and this not installed
by the 'make install': Remember, we are still at the top of
your
lirc source directory. (Some of this is not needed
if you
installed from the RPM's.)
cp contrib/lirc.redhat /etc/init.d/lircd
cp contrib/lirc.rules /etc/udev/rules.d/lirc.rules
cp remotes/mceusb /etc/lircd.conf (This one is an overwrite)
ln -s /usr/local/lib/liblirc_client.so.0 /usr/lib/liblirc_client.so.0
- In order for the lirc module to work, it must be
loaded before
the ehci_hcd USB driver. If we wish to test this
now, we
have a bit of a problem. The wireless keyboard is
USB. As
soon as we unload the driver, we loose the keyboard, and cannot enter
the commands to re-load it. We can either write a script that
un-loads the ehci_hcd driver, loads the lirc driver, and then re-loads
ehci_hcd, or we can do the following steps over the network:
(Done over
network:)
modprobe -r ehci_hcd
modprobe lirc_mceusb2
modprobe ehci_hcd
service lircd start
chkconfig lircd on
- We can now check our remote by running irw.
Press some keys on
the remote, and the pressed key function should be listed
out.
Use <control-c> to get out of irw.
If this
works as root, but not as the mythtv user, just fix the permissions on /dev/lircd
- Download my
mceusb MythTV lircrc file
and install it in /home/mythtv/.mythtv
Make sure it is just called lircrc
Check the permissions. It needs to be
accesible by
the MthTV user. UPDATE:
I am still adding
functions for some of the MythTV supporting apps. I will be adding
more, so check this file from time to
time. Help is always appreciated. The original
lircrc file
for the mceusb2 remote is here.
- MythTV expects the path to this file to be ~/.mythtv/lircrc,
the
supporting apps expect it as ~/.lircrc
Best
solution
is to create a link:
ln -s /home/mythtv/.mythtv/lircrc /home/mythtv/.lircrc
- My lircrc contains an irexec section to eject the
DVD
drive. For this to work this
script
needs to be in ~/.mythtv, needs to be executable, and irexec needs to
be running:
irexec &
- You should probably put this someplace in the
MythTV user's
startup files. Another good thing to put in lircrc would be
an
irexec directive to start mythfrontend. This way, if
mythfrontend
dies (as it occasionally does), you don't need to hunt about for the
keyboard to re-start it. (Ahhhh... Couch potato'ing at its
best.)
- If you did the above as root,
change the permissions so
that /home/mythtv/.mythtv/lircrc
is owned by the MythTV user.
- Your remote should
work now in MythTV. If it does not,
reference the lirc
install page, or on the "Fedora
Myth(TV)ology"
site.
- To make this work after a
re-boot, we need to modify our startup
files. We want to load lirc_mceusb2 early in the boot
sequence. WARNING:
We are messing with early boot stuff here. Please check your
typing, and be careful. A mistake here may render the system
un-bootable. You do still have that Fedora Core 4 boot/rescue
disk handy don't you? What follows is part of what Jarod
Wilson
does with a patch, I am just manually pasting in the lirc part:
- Open /etc/rc.d/rc.sysinit
in your favorite editor. (That in itself should make you cringe.)
- Paste in the following just after the
line that reads echo
-n $"
audio"
# lirc drivers
for module in `/sbin/modprobe -c | awk '/^alias[[:space:]]+char-major-61+[[:space:]]/ { print $3 }'`; do
load_module $module
done
- If the remote still does not work after a
re-boot, do:
ls
-al /dev/lirc* and check for
the correct
devices. You may have to edit /etc/udev/rules.d/lirc.rules to
get
it to re-create the correct devices following a re-boot. Try
deleting some or all of the /%n
off of the end.
VFD (Vaccum Flourescent Display), Front Panel
LED's and Front
Panel Keys:
The VFD is connected to one of the internal USBhubs. The VFD
Identifies itself as: Manufacturer=HP Product=HP
VFD Front
Panel Board Vendor=1460
ProdID=0024.
The Entire Front
Panel is a USB HID Device. It can be found on
/dev/input/event0
As a HID device, the keys produce normal keystrokes. I
haven't
actually done it yet, but you can use
xmodmap to map
them as you
desire. I am still figuring out how to talk to the VFD and
LED's. It will probably need a modified HID driver, or
standalone
driver. I am studying the Linux USB HID pages at:
http://www.frogmouth.net/hid-doco/linux-hid.html
Multi-Card reader and Removable Drive
Bay:
The Multi-Card reader is a standard USB 2.0 Mulit-Card
Reader.
Fedora 4 Supports it very well without doing anything.
For reference it is identified on the USB bus as: Vendor=058f
ProdID=9360.
The "Personal Media Bay" is really just another USB 2.0
connector, and a coaxial power plug. I do not have the drive
that
it uses, but I see no reason why it would not be fully supported.
ACPI (Sleep/Suspend):
This box uses a lot of power. It would be really nice to get
(at
least) suspend to RAM working. Unfortunately, I am not an
ACPI
expert, and I do not have this working yet. Any help from
someone
experienced with ACPI would be much appreciated.
Other Notes and Issues:
- I have occasional Mythfrontend crashes when
exiting for watching
live TV or a recorded program. Others have reported similar
experiences.
- Minor: The system was
causing traffic on my LAN when I did
not think it should. If I wanted things on my LAN that
mis-behaved, I would have left Windows XP on the box. I found
out
that it seemed to be constantly trying to do name resolution for some
of the things inside my LAN. I simply added my local machines
to /etc/hosts,
and the nonsense
traffic stopped. This may also be due to the fact that my
search
domain was not set correctly. I also removed all of the
Redhat
Up2Date
stuff. I'll do the updates via yum. With these
corrections, the box never speaks out of turn.
- Updated If
you are
checking back on this board after previous visits, you
will notice that I have removed some comments about a memory
leak. My system has been running for several weeks with no
crashes or miss-behavior. I have the
system "In production" now, and the whole family uses it
alot.
With things configured as above, the system comes up fine after a
re-boot. The only thing I have to do is un-mute the audio
channels.
Links:
Disuss
this article on the Linuxslate
Forums
HP
z555 Specs and Motherboard info
MythTV Home Page
Fedora Myth(TV)ology
This is a old
version of this Document.
All
trademarks/tradenames are
the property of the companies
that own them.