awalls at radix
Jul 9, 2009, 5:32 PM
Post #6 of 33
On Thu, 2009-07-09 at 23:04 +0530, Ravi A wrote:
Re: Fwd: [UNKNOWN IVTV CARD] (cx23416) AverMedia M113-C
[In reply to]
> On Wed, Jul 8, 2009 at 6:07 AM, Andy Walls<awalls [at] radix> wrote:
> >> - Checked composite and tuner inputs with /dev/video0, both are functional
> > OK, good. I' suspect I may have the chroma input for S-Video wrong.
> > Let me know if S-Video is only in black and white.
> Indeed, S-video is only in black and white.
I've pushed a patch to
to fix SVideo chroma for the M113 boards.
> >> - Composite input gives decent picture quality (although there seen to
> >> be some minor artifacts at edges of red/yellow in all players - but
> >> maybe this is the best that can be expected from this capture card?)
> > Hmmm. There may be something that can be tweaked in the cx25840 module.
> > That modules gets the most testing against the CX25843 and the CX25841
> > is slightly different.
> > Also, after setting the input to composite, you could try using v4l2-ctl
> > to set the video standard explicitly:
> > $ v4l2-ctl -d /dev/video0 -i2
> > Video input set to 2 (Composite 1)
> > $ v4l2-ctl -d /dev/video0 -s pal-B
> > Standard set to 00000007
> > $ v4l2-ctl -d /dev/video0 -S
> > Video Standard = 0x00000007
> > PAL-B/B1/G
> I tried this, but the picture did not improve. I tried all the PAL and
> even a few other standards too.
> PS: v4l2-ctl did not recognize the pal-B command argument, it kept
> setting pal-H. I had to use numeric argument. A numeric argument of 6
> sets the standard to 7 (one higher).
Hmm. That's odd. Probably some mismatch between the latest v4l-dvb
drivers and the v4l2-ctl you have. Oh well, as long as
$ v4l2-ctl -d /dev/video0 --log-status
shows you what you expect.
> posted some pics and a video clip here -
> snapshot-svideo - http://www.flickr.com/photos/26209946 [at] N0/3704069849/
> snapshot-composite - http://www.flickr.com/photos/26209946 [at] N0/3704069841/
> video-composite - http://www.flickr.com/photos/26209946 [at] N0/3704069859/
> (Can notice some dot artifacts in red/yellow region borders in all of
> the above. These are not present in direct source connection to TV)
I see them in the color snapshot. (I can't see the flash video as I
don't have a flash player). The artifacts look, at least in part, due
to the MPEG compression that the CX23416 is performing on the video. If
you notice, there seems to be some subtle artifacts around the white
lettering and the black trim of the tools. The red '@' does look bad.
You should use v4l2-ctl to list the controls (with menus) and start
playing with the MPEG settings and filters. I suspect if you don't
perform much compression at all, the artifacts will diminish.
There are some video processing controls in the CX25841 (a comb filter,
white crush, chroma coring, etc) but they are not easily manipulated
with user tools IIRC.
> >> - Tuner input - can get a picture, but has color artifacts, even after
> >> fine-tuning frequency with ivctl. Are there any settings for color
> >> sub-frequency etc I need to tune? I am using India Cable, so the
> >> frequencies and sub-carriers may be different. In any case I do not
> >> plan to use the tuner input, but can test and report back on any
> >> experiments if needed.
> > The Partsnic PTI-5NF05 tuner is an NTSC-M tuner. India is a PAL-B/G
> > country. I'm surprised you have a picture with the tuner at all.
> The box in which the card came advertises PAL/NTSC/SECAM with a globe
> icon! So I assumed it supported all standards. And yes the picture
> looks too reasonable to be coming from a mismatched standard (sync and
> size is perfectly OK, just the color information seems haywire/noisy
> or totally missing depending on the actual fine-tuned frequency
> > I don't know what chips are in the tuner. I assume an Infineon TUA6030
> > (or clone ) mixer/oscillator chip is the first stage and some othe demod
> > chip is the second stage. If I knew the chips in the tuner (dmesg
> > output?) I might be able to tweak things a little, but trying to force a
> > NTSC-M tuner to do PAL-B/G is never going to work.
> posted a picture of the tuner insides -
> http://www.flickr.com/photos/26209946 [at] N0/3704069839/
> The only IC I could find on the top side (in-line pin package in the
> 5th compartment from left) is marked -
> EPCOS M1865D
> 1847 1XS6
That's likely a SAW filter between the first mixer output and the IF
> Rest all seems to be just passives. There may be other chips on the
> bottom side, but that would need de-soldering the can to look - I can
> attempt this sometime if you think it would be useful.
There's really no need. According to the datasheet here:
The assembly is obviously an NTSC tuner.
NTSC and PAL have different bandwidths and chroma subcarrier
frequencies. The tuner assembly is going to have filters and passive
components appropriate for NTSC.
Check the *.inf file that comes with the Windows driver for your card
(Subsystem ID C0341461) and see if it alludes to the tuner type.
> dmesg output -
> [ 22.481423] Linux video capture interface: v2.00
> [ 22.527503] ivtv: Start initialization, version 1.4.1
> [ 22.527556] ivtv0: Initializing card 0
> [ 22.527558] ivtv0: Autodetected AVerMedia PVR-150 Plus / AVerTV
> M113 Partsnic (Daewoo) Tuner card (cx23416 based)
> [ 22.527644] ivtv 0000:01:00.0: PCI INT A -> GSI 21 (level, low) -> IRQ 21
> [ 22.527651] ivtv0: Unreasonably low latency timer, setting to 64 (was 32)
> [ 22.539677] cx25840 0-0044: cx25841-23 found @ 0x88 (ivtv i2c driver #0)
> [ 22.557064] tuner 0-0061: chip found @ 0xc2 (ivtv i2c driver #0)
> [ 22.574919] wm8739 0-001a: chip found @ 0x34 (ivtv i2c driver #0)
> [ 22.669312] tuner-simple 0-0061: creating new instance
> [ 22.669314] tuner-simple 0-0061: type set to 81 (Partsnic (Daewoo) PTI-5NF05)
Hmmm. No programmable demodulator apparently(?).
> [ 22.670506] ivtv0: Registered device video0 for encoder MPG (4096 kB)
> [ 22.670521] ivtv0: Registered device video32 for encoder YUV (2048 kB)
> [ 22.670535] ivtv0: Registered device vbi0 for encoder VBI (1024 kB)
> [ 22.670549] ivtv0: Registered device video24 for encoder PCM (320 kB)
> [ 22.670565] ivtv0: Registered device radio0 for encoder radio
> [ 22.670566] ivtv0: Initialized card: AVerMedia PVR-150 Plus /
> AVerTV M113 Partsnic (Daewoo) Tuner
> [ 22.670578] ivtv: End initialization
> [ 30.040086] ivtv 0000:01:00.0: firmware: requesting v4l-cx2341x-enc.fw
> [ 30.087476] ivtv0: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
> [ 30.284215] ivtv0: Encoder revision: 0x02060039
> [ 30.301111] cx25840 0-0044: firmware: requesting v4l-cx25840.fw
> [ 33.737874] cx25840 0-0044: loaded v4l-cx25840.fw firmware (16382 bytes)
> >> - S-video input - not checked yet, will do this later after getting an
> >> S-video source
> > I may have gotten S-Video color wrong. You'll get Luma (black and
> > white), but maybe not chroma (color). Let me know.
> > Also don't forget to set the video standard for the incoming signal.
> >> - Audio - it came up briefly, but missing again now. I may need to
> >> check all the other system settings for this one.
> > Hmmm. You may want to try and capture the MPEG stream to a file:
> > $ cat /dev/video0 > foo.mpg
> > and then playback the file on a machine with a known good sound setup to
> > make sure the CX25841/CX23416 is capturing the sound properly.
> > Also, set the driver to use a 48 ksps audio sample rate and not 32 ksps.
> > The cx25840 module drives the CX2584x chip's audio PLL out of its valid
> > operating range for 32 ksps audio. Most newer CX25843 chips don't seem
> > to care being told to operate too slow, but the audio PLL in some
> > CX2584x cores stop oscillating under that condition.
> I captured it using vlc and played back on a windows laptop :) The
> sound was too low and seemed very choppy (maybe not unlike that due to
> a PLL operating at the edge of its hold range!). You can notice it in
> the video clip I linked above.
> Although I did not explicitly set the sample rate, mplayer reported
> 48ksps for the captured stream.
48 ksps is the default. VLC might change it for the capture. When VLC,
or any other app, is capturing, you can use v4l2-ctl -d /dev/video0
--log-status to see how the capture is configured. (v4l2 device nodes
are multiple open.)
I'll look into what I might be able to do in the CX25840 driver about
fixing the PLL clocks.
The volume is controllable with the controls available with v4l2-ctl.
ivtv-devel mailing list
ivtv-devel [at] ivtvdriver