[pvrusb2] pvrusb2-mci-20070114 radio support - stereo?

Rick Macdonald rickm at timshel.ca
Sat Jan 20 14:18:45 CST 2007


Mike Isely wrote:
> Rick:
>
> The actual handling of mono vs stereo is up to the tuner core, not the 
> pvrusb2 driver (that is, once the pvrusb2 driver actually hands the 
> proper commands to the tuner core which is what this bug fix does).
>
> Are you sure you were running the updated pvrusb2 driver?  Look at the 
> banner it prints in your log when it starts; the snapshot ID will be a 
> part of that banner.
>   
Here's the log from boot-up:

Jan 19 23:06:18 timshel kernel: Linux video capture interface: v2.00
Jan 19 23:06:18 timshel kernel: ivtv:  ==================== START INIT 
IVTV ====================
Jan 19 23:06:18 timshel kernel: ivtv:  version 0.8.2 (tagged release) 
loading
Jan 19 23:06:18 timshel kernel: ivtv:  Linux version: 2.6.18-3-686 SMP 
mod_unload 686 REGPARM gcc-4.1
Jan 19 23:06:18 timshel kernel: ivtv:  In case of problems please 
include the debug info between
Jan 19 23:06:18 timshel kernel: ivtv:  the START INIT IVTV and END INIT 
IVTV lines, along with
Jan 19 23:06:18 timshel kernel: ivtv:  any module options, when mailing 
the ivtv-users mailinglist.
Jan 19 23:06:18 timshel kernel: ivtv0: Autodetected Hauppauge card 
(cx23416 based)
Jan 19 23:06:18 timshel kernel: ACPI: PCI Interrupt 0000:02:05.0[A] -> 
GSI 17 (level, low) -> IRQ 233
Jan 19 23:06:18 timshel kernel: ivtv0: Unreasonably low latency timer, 
setting to 64 (was 32)
Jan 19 23:06:18 timshel kernel: usbcore: registered new driver pvrusb2
Jan 19 23:06:18 timshel kernel: 
/usr/local/src/pvrusb2/pvrusb2-mci-20070119/driver/pvrusb2-main.c: 
Hauppauge WinTV-PVR-USB2 MPEG2 Encoder/Tuner : 20070119 (from www.isely.net)
Jan 19 23:06:18 timshel kernel: 
/usr/local/src/pvrusb2/pvrusb2-mci-20070119/driver/pvrusb2-main.c: Debug 
mask is 15 (0xf)
Jan 19 23:06:18 timshel kernel: usb 1-5: reset high speed USB device 
using ehci_hcd and address 3
Jan 19 23:06:18 timshel kernel: ACPI: PCI Interrupt 0000:00:1b.0[A] -> 
GSI 16 (level, low) -> IRQ 169
Jan 19 23:06:18 timshel kernel: PCI: Setting latency timer of device 
0000:00:1b.0 to 64
Jan 19 23:06:18 timshel kernel: hda_codec: Unknown model for ALC882, 
trying auto-probe from BIOS...
Jan 19 23:06:18 timshel kernel: ivtv0: loaded v4l-cx2341x-enc.fw 
firmware (262144 bytes)
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: MSP3445G-B8 found @ 0x80 
(pvrusb2_a)
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: MSP3445G-B8 supports 
radio, mode is autodetect and autoselect
Jan 19 23:06:18 timshel kernel: saa7115 1-0021: saa7115 found @ 0x42 
(pvrusb2_a)
Jan 19 23:06:18 timshel kernel: tuner 1-0043: chip found @ 0x86 (pvrusb2_a)
Jan 19 23:06:18 timshel kernel: tda9887 1-0043: tda988[5/6/7] found @ 
0x43 (tuner)
Jan 19 23:06:18 timshel kernel: tuner 1-0061: chip found @ 0xc2 (pvrusb2_a)
Jan 19 23:06:18 timshel kernel: tuner 2-0043: chip found @ 0x86 (ivtv 
i2c driver #0)
Jan 19 23:06:18 timshel kernel: tda9887 2-0043: tda988[5/6/7] found @ 
0x43 (tuner)
Jan 19 23:06:18 timshel kernel: tuner 2-0061: chip found @ 0xc2 (ivtv 
i2c driver #0)
Jan 19 23:06:18 timshel kernel: tveeprom 1-0050: Hauppauge model 29032, 
rev D158, serial# 7570160
Jan 19 23:06:18 timshel kernel: tveeprom 1-0050: tuner model is Philips 
FM1236 MK3 (idx 58, type 43)
Jan 19 23:06:18 timshel kernel: tveeprom 1-0050: TV standards NTSC(M) 
(eeprom 0x08)
Jan 19 23:06:18 timshel kernel: tveeprom 1-0050: audio processor is 
MSP3445 (idx 12)
Jan 19 23:06:18 timshel kernel: tveeprom 1-0050: decoder processor is 
SAA7115 (idx 19)
Jan 19 23:06:18 timshel kernel: tveeprom 1-0050: has radio, has IR remote
Jan 19 23:06:18 timshel kernel: tuner 1-0061: type set to 43 (Philips 
NTSC MK3 (FM1236MK3 or FM1236/F))
Jan 19 23:06:18 timshel kernel: tveeprom 2-0050: Hauppauge model 26552, 
rev F0A3, serial# 8854341
Jan 19 23:06:18 timshel kernel: tveeprom 2-0050: tuner model is TCL 
MFNM05-4 (idx 103, type 43)
Jan 19 23:06:18 timshel kernel: tveeprom 2-0050: TV standards NTSC(M) 
(eeprom 0x08)
Jan 19 23:06:18 timshel kernel: tveeprom 2-0050: audio processor is 
CX25843 (idx 37)
Jan 19 23:06:18 timshel kernel: tveeprom 2-0050: decoder processor is 
CX25843 (idx 30)
Jan 19 23:06:18 timshel kernel: tveeprom 2-0050: has radio, has no IR remote
Jan 19 23:06:18 timshel kernel: ivtv0: Autodetected Hauppauge WinTV PVR-150
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: MSP3445G-B8 rev1 = 
0x0207 rev2 = 0x2d48
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: Audio:    volume 62000
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: Audio:    balance 0 bass 
0 treble 0 loudness off
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: Standard: autodetect 
start (mono)
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: Audmode:  0x0001
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: Routing:  0x00000000 
(input) 0x00000044 (output)
Jan 19 23:06:18 timshel kernel: msp3400 1-0040: ACB:      0x0c00
Jan 19 23:06:18 timshel kernel: saa7115 1-0021: Audio frequency: 48000 Hz
Jan 19 23:06:18 timshel kernel: saa7115 1-0021: Input:           Composite 4
Jan 19 23:06:18 timshel kernel: saa7115 1-0021: Video signal:    bad
Jan 19 23:06:18 timshel kernel: saa7115 1-0021: Frequency:       50 Hz
Jan 19 23:06:18 timshel kernel: saa7115 1-0021: Detected format: BW/No color
Jan 19 23:06:18 timshel kernel: tda9887 1-0043: Data bytes: b=0x14 
c=0x30 e=0x44
Jan 19 23:06:18 timshel kernel: tuner 1-0061: Tuner mode:      analog TV
Jan 19 23:06:18 timshel kernel: tuner 1-0061: Frequency:       175.25 MHz
Jan 19 23:06:18 timshel kernel: tuner 1-0061: Standard:        0x00001000
Jan 19 23:06:18 timshel kernel: pvrusb2: Device initialization completed 
successfully.
Jan 19 23:06:18 timshel kernel: pvrusb2: registered device video0 [mpeg]
Jan 19 23:06:18 timshel kernel: pvrusb2: registered device radio0 [mpeg]
Jan 19 23:06:18 timshel kernel: cx25840 2-0044: cx25843-23 found @ 0x88 
(ivtv i2c driver #0)
Jan 19 23:06:18 timshel kernel: cx25840 2-0044: loaded v4l-cx25840.fw 
firmware (16382 bytes)
Jan 19 23:06:18 timshel kernel: wm8775 2-001b: chip found @ 0x36 (ivtv 
i2c driver #0)
Jan 19 23:06:18 timshel kernel: ivtv0: Encoder revision: 0x02050032
Jan 19 23:06:18 timshel kernel: ivtv0: Registered device video1 for 
encoder MPEG
Jan 19 23:06:18 timshel kernel: ivtv0: Registered device video32 for 
encoder YUV
Jan 19 23:06:18 timshel kernel: ivtv0: Registered device vbi0 for 
encoder VBI
Jan 19 23:06:18 timshel kernel: ivtv0: Registered device video24 for 
encoder PCM audio
Jan 19 23:06:18 timshel kernel: ivtv0: Registered device radio1 for 
encoder radio
Jan 19 23:06:18 timshel kernel: tuner 2-0061: type set to 43 (Philips 
NTSC MK3 (FM1236MK3 or FM1236/F))
Jan 19 23:06:18 timshel kernel: ivtv0: Initialized Hauppauge WinTV 
PVR-150, card #0
Jan 19 23:06:18 timshel kernel: ivtv:  ====================  END INIT 
IVTV  ====================

> We might be using different versions of the I2C modules with different 
> behavior.  For my testing last night I was running in kernel 2.6.18.1, 
> using the V4L core that was a part of that kernel.
>
> When I tested, the way I determined I was getting stereo was by flipping 
> the audio mode back and forth while listening (that control works now).  
> I could definitely hear the sound "spread" when I switched to stereo 
> mode.
>   
I tried this just now, and the sound does change, but neither is Stereo. 
When I tell it stereo, the volume drops a bit and seems thinner. It 
almost as if it was giving me just left or right through both sides, but 
this is hard to tell until I can catch some music or commercial with 
definite separation, and that's long enough to switch back and forth a 
few times.

> I have also asked my contact at Hauppauge about this, when there was a 
> question about whether or not Stereo is even there.  The answer is that 
> it is definitely there, but I was also warned that some combinations of 
> tuner types have been "harder" to get working in FM stereo mode.  He 
> didn't know which ones those were, but a difference like that between 
> our model types might have something to do with it.  After plugging in 
> the PVR USB2 device and starting the radio, do this command from the 
> shell:
>
>   cat /sys/class/pvrusb2/*/debuginfo
>
> That will dump info to the screen about the associated I2C modules.  
> Send me that output.  In addition, the system log will get a status dump 
> from everything (it will be obvious in the log); send that as well.  I 
> can use that to look for differences in the hardware between what you 
> are running and what I tested.
>   
timshel:~# cat /sys/class/pvrusb2/*/debuginfo
big lock free; ctl lock free
driver flags: initialized ok connected
Subsystems enabled / configured: +ENC_FIRMWARE +ENC_CFG +DIG_RUN 
+USB_RUN +ENC_RUN
Subsystems disabled / unconfigured:
Attached I2C modules:
tveeprom @ 0x50 [v4l2_standard v4l2_audiomode v4l2_bcsh v4l2_volume 
v4l2_freq v4l2_size v4l2_log]
MSP3445G-B8 @ 0x40 (handler: pvrusb2-audio v4l2) [v4l2_standard 
v4l2_audiomode v4l2_bcsh v4l2_volume v4l2_freq v4l2_size v4l2_log]
saa7115 @ 0x21 (handler: pvrusb2-video-v4l) [v4l2_standard 
v4l2_audiomode v4l2_bcsh v4l2_volume v4l2_freq v4l2_size v4l2_log]
tda9887 @ 0x43 (handler: pvrusb2-tuner) [v4l2_standard v4l2_audiomode 
v4l2_bcsh v4l2_volume v4l2_freq v4l2_size v4l2_log]
Philips NTSC MK3 (FM1236MK3 or FM1236/F) @ 0x61 (handler: pvrusb2-tuner) 
[v4l2_standard v4l2_audiomode v4l2_bcsh v4l2_volume v4l2_freq v4l2_size 
v4l2_log]
timshel:~#

> However, the fact that you got stereo while running under WinXP would 
> suggest that this isn't the issue.  But it could be a different enough 
> tuner that the tuner core isn't driving it correctly.  There has been at 
> least one recent commit into the v4l-dvb repository regarding proper 
> suport of FM stereo for certain tuner types.  This leads to another 
> suggestion: Check out and build the latest v4l-dvb repository and test 
> that.  The pvrusb2 driver is also a part of that repository, and in fact 
> as of this morning, all the recent changes have been pulled up into it.
>   
It might be a day or three before I can look at v4l-dvb (three birthdays 
in the family this weekend).

Question: I'm playing the radio with this:  mplayer -vo null /dev/radio0
and setting the station as root with this:   echo 89300000 > 
/sys/class/pvrusb2/sn-7570160/ctl_frequency/cur_val

Is there anything else that works?

It seemed like it worked OK the other day, but now after 5 or 10 seconds 
it dumps a bunch of stuff and gets all choppy (after it prints "too SLOW"):

==========================================================================
AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
Starting playback...
VDec: vo config request - 720 x 480 (preferred colorspace: Mpeg PES)
VDec: using Mpeg PES as output csp (no 0)
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
VO: [null] 720x480 => 720x540 Mpeg PES
A:  11.8 V:   7.3 A-V:  4.505 ct: -0.453 184/184  0%  0% 119.9% 50 0

           ************************************************
           **** Your system is too SLOW to play this!  ****
           ************************************************

Possible reasons, problems, workarounds:
- Most common: broken/buggy _audio_ driver
  - Try -ao sdl or use the OSS emulation of ALSA.
  - Experiment with different values for -autosync, 30 is a good start.
- Slow video output
  - Try a different -vo driver (-vo help for a list) or try -framedrop!
- Slow CPU
  - Don't try to play a big DVD/DivX on a slow CPU! Try some of the 
lavdopts,
    e.g. -vfm ffmpeg -lavdopts lowres=1:fast:skiploopfilter=all.
- Broken file
  - Try various combinations of -nobps -ni -forceidx -mc 0.
- Slow media (NFS/SMB mounts, DVD, VCD etc)
  - Try -cache 8192.
- Are you using -cache to play a non-interleaved AVI file?
  - Try -nocache.
Read DOCS/HTML/en/video.html for tuning/speedup tips.
If none of this helps you, read DOCS/HTML/en/bugreports.html.

A:  18.7 V:   8.3 A-V: 10.365 ct: -0.369 213/213  0%  0% 198.0% 79 0
Too many video packets in the buffer: (4096 in 7952696 bytes).
Maybe you are playing a non-interleaved stream/file or the codec failed?
For AVI files, try to force non-interleaved mode with the -ni option.


> Can anyone else confirm / deny operation of the FM radio in stereo mode?
>
>   -Mike
>
>   



More information about the pvrusb2 mailing list