Wednesday, June 22, 2005

MythVideo installation

Remove plugins files/subdir. Sync with CVS state on 4/22/05:

cd ~/cvs
cvs -z3 -d :pserver:mythtv@cvs.mythtv.org:/var/lib/mythcvs checkout -D "2005-04-22" mythplugins

From mythtv howto:
$ ./configure --disable-all --enable-mythvideo
$ qmake mythplugins.pro
$ make
$ su
# make install

Ran mythtv. Went to setup for video files. Set files dir to /mythtv/video/

Set player command to:
mplayer ... -monitoraspect 16:9 -vo xv -ao alsa:device=digital2c

With English audio by default:
mplayer dvd:// -dvd-device %d -fs -zoom -monitoraspect 16:9 -vo xv -ao alsa:device=hw=1.0 -alang en

Refresh video library/files list: Setup/Utilites, Video Manager [or find the setting to always display files found in the video subdir]

Note, that xvid was previously installed. See blog entry for Sunday, April 24, 2005. So everything just "worked"; at least xvid file playback.

Turtle Beach Riviera installation

ALSA recognized the new card (card 1):

[root@be ~]# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: ICH5 [Intel ICH5], device 0: Intel ICH [Intel ICH5]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: ICH5 [Intel ICH5], device 4: Intel ICH - IEC958 [Intel ICH5 - IEC958
]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: CMI8738MC6 [C-Media PCI CMI8738-MC6], device 0: CMI8738-MC6 [C-Media
PCI DAC/ADC]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: CMI8738MC6 [C-Media PCI CMI8738-MC6], device 1: CMI8738-MC6 [C-Media
PCI 2nd DAC]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: CMI8738MC6 [C-Media PCI CMI8738-MC6], device 2: CMI8738-MC6 [C-Media
PCI IEC958]
Subdevices: 1/1
Subdevice #0: subdevice #0

Added to .asoundrc:

pcm.digital2 {
type plug
slave.pcm "digital-hw2"
}
pcm.digital-hw2 {
type hw
card 1
device 0
}

pcm.digital2b {
type plug
slave.pcm "digital-hw2b"
}
pcm.digital-hw2b {
type hw
card 1
device 1
}

pcm.digital2c {
type plug
slave.pcm "digital-hw2c"
}
pcm.digital-hw2c {
type hw
card 1
device 2
}

aplay of .wav failed:
# aplay -D digital2 bustin.wav
# aplay -D digital2b bustin.wav
# aplay -D digital2c bustin.wav

Looked in alsamixer:
# alsamixer -c1

"Item: IEC958 Output" was MUTED. Unmuted this and...

# aplay -D digital2c bustin.wav [WORKED!]

(This is card 1, device 2).

Save settings:
# /sbin/alsactl store

Note, that I later saved the mixer settings to a file with:
# alsactl -f /root/asound.settings.riviera store

Default location is /etc/asound.settings

Changed setup in MythTV (Settings->General):
Was: ALSA:digital
Changed to: ALSA:digital2c

WORKED!

====================================
Now, xine. Added to .asoundrc:

Card 1, Device 2:

pcm.!iec958 {
type plug
slave.pcm "hw:1,2"
}
ctl.!iec958 {
type hw
card 1
}

# xine -pfhq --no-splash --verbose dvd:///dev/hdb > tmp_xine.txt

Xine settings (Alt-S, Audio tab):

Audio driver: alsa
Use a/52 dynamic range compression: Unchecked
Downmix audio to 2 channel surround stereo: Unchecked
A/52 volume: slider all the way to the RIGHT
device used for mono: digital2c
device used for stereo: digital2c
alsa mixer device: Master
Sound card can do mmap: Unchecked
Device used for 5.1 channel output (device.alsa_passthough_de): iec958
Device used for 4 channel output: plug:surround40:0
Device used for 5.1 channel output: plug:surround51:0
Speaker arrangement: Pass Through
offset for digital passthrough: 0
Method to sync audio and video: metronom feedback
Always resample to this rate: 0 (disable)
Enable resampling: auto
Startup audio volume: slide in the MIDDLE
Restore volume level at startup: Unchecked

No sound. So tested bustin.wav (this time in KDE):
# aplay -D digital2c bustin.wav

No sound! So restored mixer settings to fix this:
# /sbin/alsactl restore

alsamixer settings:
Master: 90
3D Contr: MUTED
PCM: 77
Synth: 77
Line: Muted
Line-in as bass: M)uted
Line-in as rear: M
CD: M
Mic: M
Mic Capt: 0
Mic as center/lfe: 0
Mic Boost: M
IEC958 5V: 0
IEC958 Copyright: M
iec958 in monitor: M
iec958 in phase inverse: M
iec958 in select: M
iec958 in valid: M
iec958 in loop: M
iec958 output: 0
pc speaker: 67
aux: M
Four channel mode: 0

Now running xine has DTS sound off DVD! :-)

Wednesday, June 08, 2005

Automatically start frontend when PC boots

Added to /etc/rc.d/rc.local:
su root -c "startx > /var/tmp/startx.log &" &

/root/.xinitrc contains only one line:

/usr/local/bin/mythfrontend

When quitting frontend, returns to non-X shell.

Tuesday, June 07, 2005

HDTV MythTV is stable :-)

19 days of stability and viewing enjoyment:

[root@myth sandbox]# uptime
00:28:01 up 19 days, 9:13, 5 users, load average: 0.58, 0.46, 0.37