Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Resolved] MythTV: cat /dev/video0 causes lockup
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
cynric
Guru
Guru


Joined: 08 Oct 2004
Posts: 439

PostPosted: Mon Feb 13, 2006 3:41 am    Post subject: [Resolved] MythTV: cat /dev/video0 causes lockup Reply with quote

I've been through all the threads containing "cat video0 ptune" and haven't seen an answer or, for that matter, anyone else with a similiar problem. I've looked at the comcast.net/~alf_park howto, everything on gentoo-wiki about "mythtv" and "pvr 150".

In the kernel, instead of using modules for the i2c and v4l stuff, I just built them in. `lsmod` only has ivtv. Firing up X kicks in alsa. Here's some relevant kernel options:
Code:
CONFIG_HOTPLUG=y

# I2C support
CONFIG_I2C=y
CONFIG_I2C_CHARDEV=y
# I2C Algorithms
CONFIG_I2C_ALGOBIT=y
CONFIG_I2C_VIAPRO=y

CONFIG_ACPI_VIDEO=y
CONFIG_VIDEO_DEV=y
CONFIG_VIDEO_BT848=y
CONFIG_VIDEO_AUDIO_DECODER=y
CONFIG_VIDEO_DECODER=y
CONFIG_VIDEO_TUNER=y
CONFIG_VIDEO_BUF=y
CONFIG_VIDEO_BTCX=y
CONFIG_VIDEO_IR=y
CONFIG_VIDEO_TVEEPROM=y


The video card is a WinTV-PVR 150 (model: HAU 1045)
Code:
lspci |grep video
00:0a.0 Multimedia video controller: Internext Compression Inc iTVC16 (CX23416) MPEG-2 Encoder (rev 01)


emerge info
Code:
Portage 2.0.54 (default-linux/x86/2005.1, gcc-3.3.5-20050130, glibc-2.3.5-r2, 2.6.15-gentoo-r1 i686)
=================================================================
System uname: 2.6.15-gentoo-r1 i686 AMD Athlon(tm) XP 1700+
Gentoo Base System version 1.6.14
dev-lang/python:     2.3.5-r2, 2.4.2
sys-apps/sandbox:    1.2.11
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon-xp -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon-xp -O2 -pipe"
<snip>


Relevant packages:
Code:
Calculating dependencies ...done!
[ebuild   R   ] media-tv/ivtv-0.4.2-r1 
[ebuild   R   ] media-tv/mythtv-0.18.1-r1 
[ebuild   R   ] dev-db/mysql-4.1.14 
[ebuild   R   ] media-video/mplayer-1.0_pre7-r1 
[ebuild   R   ] media-tv/ivtv-ptune-0.2.0_rc3 
[ebuild   R   ] x11-base/xorg-x11-6.8.2-r6


cat /etc/modules.d/ivtv
Code:
alias char-major-81     videodev
alias char-major-81-0   ivtv
alias char-major-81-1   ivtv
options ivtv ivtv_std=1 tuner=57
#alias char-major-61 lirc_i2c
#add above ivtv lirc_dev lirc_i2c


dmesg |grep ivtv
Code:
ivtv:  ==================== START INIT IVTV ====================
ivtv:  version 0.4.2 (tagged release) loading
ivtv:  Linux version: 2.6.15-gentoo-r1 preempt K7 gcc-3.3
ivtv:  In case of problems please include the debug info between
ivtv:  the START INIT IVTV and END INIT IVTV lines, along with
ivtv:  any module options, when mailing the ivtv-users mailinglist.
ivtv0: Autodetected WinTV PVR 150 card (cx23416 based)
ivtv0: Unreasonably low latency timer, setting to 64 (was 32)
wm8775 1-001b: chip found @ 0x36 (ivtv i2c driver #0)
ivtv0: i2c attach to card #0 ok [client=wm8775, addr=1b]
tuner 1-0061: chip found @ 0xc2 (ivtv i2c driver #0)
ivtv0: i2c attach to card #0 ok [client=(tuner unset), addr=61]
ivtv0: i2c attach to card #0 ok [client=tveeprom, addr=50]
cx25840 1-0044: cx25841-23 found @ 0x88 (ivtv i2c driver #0)
ivtv0: i2c attach to card #0 ok [client=cx25840, addr=44]
ivtv0: loaded v4l-cx2341x-enc.fw firmware (262144 bytes)
ivtv0: Encoder revision: 0x02050032
ivtv0: Allocate DMA encoder MPEG stream: 128 x 32768 buffers (4096KB total)
ivtv0: Allocate DMA encoder YUV stream: 194 x 10800 buffers (2048KB total)
ivtv0: Allocate DMA encoder VBI stream: 120 x 17472 buffers (2048KB total)
ivtv0: Allocate DMA encoder PCM audio stream: 455 x 4608 buffers (2048KB total)
ivtv0: Initialized WinTV PVR 150, card #0
ivtv:  ====================  END INIT IVTV  ====================


dmesg |grep tuner
Code:
tuner 1-0061: chip found @ 0xc2 (ivtv i2c driver #0)
ivtv0: i2c attach to card #0 ok [client=(tuner unset), addr=61]
tveeprom 1-0050: tuner model is TCL 2002N 5H (idx 99, type 50)
tuner 1-0061: type set to 57 (Philips FQ1236A MK4)


Everything seems to be in working order except that any access of /dev/video0 causes the system to hardlock. Any ideas would be greatly appreciated. If anyone needs more info, I can provide it.


Last edited by cynric on Fri Feb 24, 2006 2:40 am; edited 1 time in total
Back to top
View user's profile Send private message
cynric
Guru
Guru


Joined: 08 Oct 2004
Posts: 439

PostPosted: Mon Feb 13, 2006 10:49 pm    Post subject: Reply with quote

Still haven't gotten anywhere with this. I should have mentioned whether or not I used ptune and ivtvctl. Here's the two examples I've done. Of course, I've tried various other settings, but have pretty much stuck to the layout below.

Code:
#ptune
ptune.pl --input /dev/video0 -c 2
ptune.pl --input /dev/video0 -c 2 -f ntsc-cable-hrc

#ivtvctl
ivtvctl -u 0x3000 -p 4 -f width=720,height=480 -v input=3,output=1


I've also tried `cat`ing before doing any tuning. I do apparently have one IRQ conflict:

Code:
dmesg |grep -i irq |grep -i disabl
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled


Another bit of info from `ivtv -a`:
Code:
ivtvctl -a
ioctl IVTV_IOC_G_CODEC ok
Codec parameters
aspect      : 2
audio       : 0x00e9
bframes     : 3
bitrate_mode: 0
bitrate     : 8000000
bitrate_peak: 9600000
dnr_mode    : 0
dnr_spatial : 0
dnr_temporal: 8
dnr_type    : 0
framerate   : 0
framespergop: 15
gop_closure : 1
pulldown    : 0
stream_type : 14
ioctl VIDIOC_G_FMT ok
        Type   : Video Capture
        Width  : 720
        Height : 480
ioctl VIDIOC_QUERYCAP ok
        Driver name   : ivtv
        Card type     : WinTV PVR 150
        Bus info      : 0000:00:0a.0
        Driver version: 1026
        Capabilities  : 0x01030011
ioctl: VIDIOC_ENUMINPUT
        Input   : 0
        Name    : Tuner
        Type    : 0x00000001
        Audioset: 0x00000003
        Tuner   : 0x00000000
        Standard: 0x0000000000003000 ( NTSC )
        Status  : 0

        Input   : 1
        Name    : Composite 0
        Type    : 0x00000002
        Audioset: 0x00000003
        Tuner   : 0x00000000
        Standard: 0x00000000007F7FFF ( PAL NTSC SECAM )
        Status  : 0

        Input   : 2
        Name    : Composite 1
        Type    : 0x00000002
        Audioset: 0x00000003
        Tuner   : 0x00000000
        Standard: 0x00000000007F7FFF ( PAL NTSC SECAM )
        Status  : 0

        Input   : 3
        Name    : S-Video 0
        Type    : 0x00000002
        Audioset: 0x00000003
        Tuner   : 0x00000000
        Standard: 0x00000000007F7FFF ( PAL NTSC SECAM )
        Status  : 0

        Input   : 4
        Name    : S-Video 1
        Type    : 0x00000002
        Audioset: 0x00000003
        Tuner   : 0x00000000
        Standard: 0x00000000007F7FFF ( PAL NTSC SECAM )
        Status  : 0
ioctl VIDIOC_G_INPUT ok
Video input = 0
ioctl: VIDIOC_ENUMOUTPUT
ioctl VIDIOC_G_OUTPUT failed: Invalid argument
ioctl: VIDIOC_ENUMAUDIO
        Input   : 0
        Name    : Tuner Audio In

        Input   : 1
        Name    : Audio Line 1

        Input   : 2
        Name    : Audio Line 2

        Input   : 3
        Name    : Audio Line 3

        Input   : 4
        Name    : Audio Line 4
ioctl VIDIOC_G_AUDIO ok
Audio input = 0: Tuner Audio In
ioctl VIDIOC_G_FREQUENCY ok
Frequency = 1236
ioctl: VIDIOC_ENUMSTD
        index       : 0
        ID          : 0x0000000000003000
        Name        : NTSC
        Frame period: 1001/30000
        Frame lines : 525

        index       : 1
        ID          : 0x00000000000000FF
        Name        : PAL
        Frame period: 1/25
        Frame lines : 625

        index       : 2
        ID          : 0x00000000007F0000
        Name        : SECAM
        Frame period: 1/25
        Frame lines : 625
ioctl VIDIOC_G_STD ok
Video standard = 0x00003000
ioctl: VIDIOC_QUERYCTRL
Brightness = 383
Contrast = 63
Saturation = 63
Hue = 0
Volume = 60928
Mute = 0
Back to top
View user's profile Send private message
cynric
Guru
Guru


Joined: 08 Oct 2004
Posts: 439

PostPosted: Fri Feb 24, 2006 2:39 am    Post subject: Reply with quote

This particular tid-bit finally sunk in a few days ago and I thought I'd go ahead and post the problem. The motherboard on this machine is a SY-K7V Dragon Plus! which is apparently based off the VIA 266 chipset. As per the IVTV Troubleshooting guide:
Quote:
If you have a Via motherboard, particularly with the KT266-400 chipset, see Via motherboard problems


It's been said that BIOS upgrades might work, but I've yet to give it a whirl as I don't have the time to pick up the pieces if it comes to that. If anyone is interested, I can make sure to post back otherwise I'll probably leave this thread as is.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum