|
|
This is an old document of little practical value. I'm leaving it here in case I can find some use in it. At least it documents the pain.
I've spent an inordinate amount of time trying to set up MythTV, an application for watching TV on a computer running Linux or possibly FreeBSD. It seems that just about everybody who has installed MythTV has had significant problems, and my main concern is that I might install it, get it to work, and then have to go through the same pain next time I try to install it. This page is intended to remind me of the steps. It's mainly for my own reference, but it may help others.
This stuff is now significantly out of date. I've since ported MythTV to FreeBSD, and I'm writing a separate page for FreeBSD.
Note also the MythTV HOWTO.
So: install
# yum install xorg-x11-devel xorg-x11-doc zvbi zvbi-devel
You don't really need the xorg-x11-doc, but it goes against the grain to omit documentation. Why, in these days of sub-terabyte disk drives, do distributors make separate packages of them?
# wget http://dl.bytesex.org/releases/xawtv/xawtv-3.95.tar.gz
Get the system up to date:
yum upgrade
# cd /etc/yum.repos.d/ # wget http://wilsonet.com/mythtv/atrpms.repo # wget http://wilsonet.com/mythtv/freshrpms.repoJarod goes into some detail on what to do if these steps go wrong.
Possibly set up audio. Jarod describes this, but it doesn't seem to be necessary on my hardware.
Install an analogue tuner. Mine is an MSI “TV@nywhere Master” (who thinks out these names?), which includes a remote control. It is detected immediately by the kernel:
CORE cx88[0]: subsystem: 1462:8606, board: MSI TV-@nywhere Master [card=7,autodetected] TV tuner 33 at 0x1fe, Radio tuner -1 at 0x1fe i2c_adapter i2c-0: nForce2 SMBus adapter at 0x5000 i2c_adapter i2c-1: nForce2 SMBus adapter at 0x5040 ohci_hcd: 2005 April 22 USB 1.1 'Open' Host Controller (OHCI) Driver (PCI) input: cx88 IR (MSI TV-@nywhere Master as /class/input/input2 cx88[0]/0: found at 0000:01:08.0, rev: 5, irq: 10, latency: 32, mmio: 0xe6000000 tuner 2-0061: chip found @ 0xc2 (cx88[0]) tuner 2-0061: microtune: companycode=3cbf part=42 rev=22 tuner 2-0061: microtune MT2050 found, OK tda9887 2-0043: chip found @ 0x86 (cx88[0]) cx88[0]/0: registered device video0 [v4l2] cx88[0]/0: registered device vbi0 cx88[0]/0: registered device radio0 set_control id=0x980900 reg=0x310110 val=0x00 (mask 0xff) set_control id=0x980901 reg=0x310110 val=0x3f00 (mask 0xff00) set_control id=0x980903 reg=0x310118 val=0x00 (mask 0xff) set_control id=0x980902 reg=0x310114 val=0x5a7f (mask 0xffff) set_control id=0x980909 reg=0x320594 val=0x40 (mask 0x40) [shadowed] set_control id=0x980905 reg=0x320594 val=0x20 (mask 0x3f) [shadowed] set_control id=0x980906 reg=0x320598 val=0x40 (mask 0x7f) [shadowed]
This driver also handles the remote control; other cards with a remote control interface may not be recognized. Potentially lirc can help there, but I haven't investigated that yet.
02:00.0 VGA compatible controller: Silicon Integrated Systems [SiS] 315PRO PCI/AGP VGA Display Adapter (prog-if 00 [VGA]) Subsystem: Silicon Integrated Systems [SiS] 315PRO PCI/AGP VGA Display Adapter Flags: bus master, 66MHz, medium devsel, latency 39, IRQ 5 BIST result: 00 Memory at d0000000 (32-bit, prefetchable) [size=256M] Memory at e5000000 (32-bit, non-prefetchable) [size=256K] I/O ports at c000 [size=128] [virtual] Expansion ROM at e4000000 [disabled] [size=64K] Capabilities: [40] Power Management version 2 Capabilities: [50] AGP version 2.0
Create a user mythtv. Give it the home directory /home/mythv.
mkdir -p ~mythtv/sources/sis_drv cd ~mythtv/sources/sis_drv wget http://www.winischhofer.net/sis/sis_drv.o_xorg_6.9.0_gcc4_091205-1.tar.gz tar -xzvf sis_drv.o_xorg_gcc3_current.tar.gz mv /usr/lib/xorg/modules/drivers/sis_drv.so /usr/lib/xorg/modules/drivers/sis_drv.so.orig cp -p sis_drv.so /usr/lib/xorg/modules/drivers/sis_drv.soIt's very likely that the name http://www.winischhofer.net/sis/sis_drv.o_xorg_6.9.0_gcc4_091205-1.tar.gz will change; the SiS chipset overview and the directory listing of http://www.winischhofer.net/sis/ may help further. In this version, I'm looking for the file sis_drv.so.
Get MythTV:
# yum install mythtv-suite
Install lirc:
# yum install lirc-kmdl-`uname -r` # yum install lircJarod suggests storing the result of the uname -r invocation in a variable KVER, so this could also be:
# yum install lirc-kmdl-$KVER # yum install lircSetting up lirc is a particularly painful process. In my case, use the following:
# wget http://www.lemis.com/grog/programs/multimedia/TVatnywhere # cat TVatnywhere >> /etc/lircd.conf
I: Bus=0001 Vendor=1462 Product=8606 Version=0001 N: Name="cx88 IR (MSI TV-@nywhere Master" P: Phys=pci-0000:01:08.0/ir0 S: Sysfs=/class/input/input2 H: Handlers=kbd event2 B: EV=100003 B: KEY=20c0000 800000 0 0 0 4 10000 100 0 1e0000 0 2 10100ffc
The 2 in the line starting with H: gives the clue as to the device name; it's /dev/input/event2.
Start lircd like this:
# lircd -H dev/input -d /dev/input/event2
# irrecord -W dev/input -d /dev/input/event2Follow the instructions.
# /sbin/chkconfig mysqld on # /sbin/service mysqld start
This registers mysqld (the MySQL server) as a service that should be started on boot, and then starts it.
Set the mysql root password. Replace ROOT_PWD with your password
# mysql -u root mysql mysql> UPDATE user SET Password=PASSWORD('ROOT_PWD') WHERE user='root'; mysql> FLUSH PRIVILEGES; mysql> quit
Next, create mythconverg, the MythTV database:
$ mysql -u root -p < /usr/share/doc/mythtv-0.19/database/mc.sqlEnter the password you just set above when prompted.
Create a directory for storing video, and give it to user mythtv:
# mkdir /spool/video # chown mythtv /spool/video # chmod 777 /spool/video
I have my doubts about setting the permissions to 777, but that's what the MythTV HOWTO says.
# Make sure anybody can access multimedia interfaces. The boot # sequence seems to give them back to root. chmod 666 /dev/adsp /dev/audio /dev/dsp /dev/mixer /dev/sequencer \ /dev/sequencer2 /dev/radio0 /dev/vbi0 /dev/video0 /dev/snd/*
Greg's home page | Greg's diary | Greg's photos | ||
$Id: mythtv-setup.html,v 1.8 2009/07/20 23:45:42 grog Exp $ |