Mailing List Archive

How to disable audio AGC on a PVR-150?
Hi,

I have a PVR-150 and am trying to resolve what appears to be exactly the
same
issue as is described for Windows users at
http://gl.tter.org/pvr150_distortion/
i.e. the WM8775 has an automatic gain control circuit which is by default
clipping the audio at around -6 db, so to get undistorted sound I need to
record it very quietly, using `v4l2-ctl -c volume=...`

I'm guessing this problem is typical on Linux as well for the PVR-150,
as I've
seen people instructed to make sure the volume is "below 75%" (although
"75%"
isn't low enough for me).
I haven't been able to figure out how to deal with the problem in Linux,
but
the comments by "LightWeightProducer" at
http://forum.videohelp.com/threads/323623-capture-VHS-with-Hauppauge-PVR-150

lead me to believe it is possible. I thought maybe the answer was using
i2c-tools, but so far that is beyond me. Can anybody point me in the right
direction?

Thanks,
Alister

uname -a:

Linux archie 3.17.6-1-ARCH #1 SMP PREEMPT Sun Dec 7 23:58:19 UTC 2014
i686 GNU/Linux

lspci -v:

01:06.0 Multimedia video controller: Internext Compression Inc iTVC16
(CX23416) Video Decoder (rev 01)
Subsystem: Hauppauge computer works Inc. WinTV PVR 150
Flags: bus master, medium devsel, latency 128, IRQ 18
Memory at e8000000 (32-bit, prefetchable) [size=64M]
Capabilities: [44] Power Management version 2
Kernel driver in use: ivtv
Kernel modules: ivtv

dmesg:

[ 10.302703] ivtv: Start initialization, version 1.4.3
[ 10.302787] ivtv0: Initializing card 0
[ 10.302789] ivtv0: Autodetected Hauppauge card (cx23416 based)
[ 10.303066] ACPI: PCI Interrupt Link [APC3] enabled at IRQ 18
[ 10.355501] tveeprom 0-0050: The eeprom says no radio is present, but
the tuner type
[ 10.355503] tveeprom 0-0050: indicates otherwise. I will assume that
radio is present.
[ 10.355505] tveeprom 0-0050: Hauppauge model 26589, rev C9A5, serial#
9488343
[ 10.355507] tveeprom 0-0050: tuner model is TCL MPE05-2 (idx 105,
type 38)
[ 10.355509] tveeprom 0-0050: TV standards PAL(B/G) PAL(I) SECAM(L/L')
PAL(D/D1/K) (eeprom 0x74)
[ 10.355511] tveeprom 0-0050: audio processor is CX25843 (idx 37)
[ 10.355512] tveeprom 0-0050: decoder processor is CX25843 (idx 30)
[ 10.355514] tveeprom 0-0050: has radio
[ 10.355515] ivtv0: Autodetected Hauppauge WinTV PVR-150
[ 10.494117] forcedeth 0000:00:0f.0: ifname eth0, PHY OUI 0x732 @ 13,
addr 00:22:68:49:38:5c
[ 10.494121] forcedeth 0000:00:0f.0: highdma pwrctl mgmt lnktim msi
desc-v3
[ 10.494328] i2c i2c-1: nForce2 SMBus adapter at 0x1c00
[ 10.494354] i2c i2c-2: nForce2 SMBus adapter at 0x1c80
[ 10.494733] ACPI: PCI Interrupt Link [AAZA] enabled at IRQ 23
[ 10.494741] snd_hda_intel 0000:00:09.0: Disabling MSI
[ 10.522200] cx25840 0-0044: cx25843-23 found @ 0x88 (ivtv i2c driver #0)
[ 10.545557] input: PC Speaker as /devices/platform/pcspkr/input/input3
[ 10.666390] input: Microsoft Microsoft 3-Button Mouse with
IntelliEye(TM) as
/devices/pci0000:00/0000:00:04.0/usb1/1-1/1-1:1.0/0003:045E:0040.0001/input/input4
[ 10.666504] hid-generic 0003:045E:0040.0001: input,hidraw0: USB HID
v1.10 Mouse [Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)] on
usb-0000:00:04.0-1/input0
[ 10.710057] mousedev: PS/2 mouse device common for all mice
[ 10.789720] cfg80211: Calling CRDA to update world regulatory domain
[ 10.976707] usb 2-9: reset high-speed USB device number 5 using ehci-pci
[ 11.161468] tda9887 0-0043: creating new instance
[ 11.161472] tda9887 0-0043: tda988[5/6/7] found
[ 11.162493] tuner 0-0043: Tuner 74 found with type(s) Radio TV.
[ 11.163586] tuner 0-0061: Tuner -1 found with type(s) Radio TV.
[ 11.173357] sound hdaudioC0D0: ALC1200: SKU not ready 0x411111f0
[ 11.240014] sound hdaudioC0D0: autoconfig: line_outs=4
(0x14/0x15/0x16/0x17/0x0) type:line
[ 11.240019] sound hdaudioC0D0: speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
[ 11.240023] sound hdaudioC0D0: hp_outs=1 (0x1b/0x0/0x0/0x0/0x0)
[ 11.240026] sound hdaudioC0D0: mono: mono_out=0x0
[ 11.240029] sound hdaudioC0D0: dig-out=0x1e/0x0
[ 11.240032] sound hdaudioC0D0: inputs:
[ 11.240036] sound hdaudioC0D0: Front Mic=0x19
[ 11.240039] sound hdaudioC0D0: Rear Mic=0x18
[ 11.240042] sound hdaudioC0D0: Line=0x1c
[ 11.240045] sound hdaudioC0D0: dig-in=0x1f
[ 11.277297] wm8775 0-001b: chip found @ 0x36 (ivtv i2c driver #0)
[ 11.453206] ieee80211 phy0: rt2x00_set_chip: Info - Chipset detected
- rt: 2573, rf: 0002, rev: 000a
[ 11.518256] ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
[ 11.518983] usbcore: registered new interface driver rt73usb
[ 11.582579] tuner-simple 0-0061: creating new instance
[ 11.582583] tuner-simple 0-0061: type set to 56 (Philips PAL/SECAM
multi (FQ1216AME MK4))
[ 11.584860] ivtv0: Registered device video0 for encoder MPG (4096 kB)
[ 11.584899] ivtv0: Registered device video32 for encoder YUV (2048 kB)
[ 11.584935] ivtv0: Registered device vbi0 for encoder VBI (1024 kB)
[ 11.584969] ivtv0: Registered device video24 for encoder PCM (320 kB)
[ 11.585002] ivtv0: Registered device radio0 for encoder radio
[ 11.585004] ivtv0: Initialized card: Hauppauge WinTV PVR-150
[ 11.585049] ivtv: End initialization


_______________________________________________
ivtv-users mailing list
ivtv-users@ivtvdriver.org
http://ivtvdriver.org/mailman/listinfo/ivtv-users
Re: How to disable audio AGC on a PVR-150? [ In reply to ]
Is this likely to affect -250 and -350 recordings as well,
or is the particular bug only relevant to -150 chipsets?

_______________________________________________
ivtv-users mailing list
ivtv-users@ivtvdriver.org
http://ivtvdriver.org/mailman/listinfo/ivtv-users
Re: How to disable audio AGC on a PVR-150? [ In reply to ]
Andy Walls wrote on 10/05/15 05:01:
> On May 9, 2015 12:12:45 PM EDT, Alister Hood <alister.hood@gmail.com> wrote:
>> Hi,
>>
>> I have a PVR-150 and am trying to resolve what appears to be exactly
>> the
>> same
>> issue as is described for Windows users at
>> http://gl.tter.org/pvr150_distortion/
>> i.e. the WM8775 has an automatic gain control circuit which is by
>> default
>> clipping the audio at around -6 db, so to get undistorted sound I need
>> to
>> record it very quietly, using `v4l2-ctl -c volume=...`
>>
>> I'm guessing this problem is typical on Linux as well for the PVR-150,
>> as I've
>> seen people instructed to make sure the volume is "below 75%" (although
>>
>> "75%"
>> isn't low enough for me).
>> I haven't been able to figure out how to deal with the problem in
>> Linux,
>> but
>> the comments by "LightWeightProducer" at
>> http://forum.videohelp.com/threads/323623-capture-VHS-with-Hauppauge-PVR-150
>>
>>
>> lead me to believe it is possible. I thought maybe the answer was
>> using
>> i2c-tools, but so far that is beyond me. Can anybody point me in the
>> right
>> direction?
>>
>> Thanks,
>> Alister
>>
>> uname -a:
>>
>> Linux archie 3.17.6-1-ARCH #1 SMP PREEMPT Sun Dec 7 23:58:19 UTC 2014
>> i686 GNU/Linux
>>
>> lspci -v:
>>
>> 01:06.0 Multimedia video controller: Internext Compression Inc iTVC16
>> (CX23416) Video Decoder (rev 01)
>> Subsystem: Hauppauge computer works Inc. WinTV PVR 150
>> Flags: bus master, medium devsel, latency 128, IRQ 18
>> Memory at e8000000 (32-bit, prefetchable) [size=64M]
>> Capabilities: [44] Power Management version 2
>> Kernel driver in use: ivtv
>> Kernel modules: ivtv
>>
>> dmesg:
>>
>> [ 10.302703] ivtv: Start initialization, version 1.4.3
>> [ 10.302787] ivtv0: Initializing card 0
>> [ 10.302789] ivtv0: Autodetected Hauppauge card (cx23416 based)
>> [ 10.303066] ACPI: PCI Interrupt Link [APC3] enabled at IRQ 18
>> [ 10.355501] tveeprom 0-0050: The eeprom says no radio is present,
>> but
>> the tuner type
>> [ 10.355503] tveeprom 0-0050: indicates otherwise. I will assume that
>>
>> radio is present.
>> [ 10.355505] tveeprom 0-0050: Hauppauge model 26589, rev C9A5,
>> serial#
>> 9488343
>> [ 10.355507] tveeprom 0-0050: tuner model is TCL MPE05-2 (idx 105,
>> type 38)
>> [ 10.355509] tveeprom 0-0050: TV standards PAL(B/G) PAL(I)
>> SECAM(L/L')
>> PAL(D/D1/K) (eeprom 0x74)
>> [ 10.355511] tveeprom 0-0050: audio processor is CX25843 (idx 37)
>> [ 10.355512] tveeprom 0-0050: decoder processor is CX25843 (idx 30)
>> [ 10.355514] tveeprom 0-0050: has radio
>> [ 10.355515] ivtv0: Autodetected Hauppauge WinTV PVR-150
>> [ 10.494117] forcedeth 0000:00:0f.0: ifname eth0, PHY OUI 0x732 @ 13,
>>
>> addr 00:22:68:49:38:5c
>> [ 10.494121] forcedeth 0000:00:0f.0: highdma pwrctl mgmt lnktim msi
>> desc-v3
>> [ 10.494328] i2c i2c-1: nForce2 SMBus adapter at 0x1c00
>> [ 10.494354] i2c i2c-2: nForce2 SMBus adapter at 0x1c80
>> [ 10.494733] ACPI: PCI Interrupt Link [AAZA] enabled at IRQ 23
>> [ 10.494741] snd_hda_intel 0000:00:09.0: Disabling MSI
>> [ 10.522200] cx25840 0-0044: cx25843-23 found @ 0x88 (ivtv i2c driver
>> #0)
>> [ 10.545557] input: PC Speaker as
>> /devices/platform/pcspkr/input/input3
>> [ 10.666390] input: Microsoft Microsoft 3-Button Mouse with
>> IntelliEye(TM) as
>> /devices/pci0000:00/0000:00:04.0/usb1/1-1/1-1:1.0/0003:045E:0040.0001/input/input4
>> [ 10.666504] hid-generic 0003:045E:0040.0001: input,hidraw0: USB HID
>> v1.10 Mouse [Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)] on
>>
>> usb-0000:00:04.0-1/input0
>> [ 10.710057] mousedev: PS/2 mouse device common for all mice
>> [ 10.789720] cfg80211: Calling CRDA to update world regulatory domain
>> [ 10.976707] usb 2-9: reset high-speed USB device number 5 using
>> ehci-pci
>> [ 11.161468] tda9887 0-0043: creating new instance
>> [ 11.161472] tda9887 0-0043: tda988[5/6/7] found
>> [ 11.162493] tuner 0-0043: Tuner 74 found with type(s) Radio TV.
>> [ 11.163586] tuner 0-0061: Tuner -1 found with type(s) Radio TV.
>> [ 11.173357] sound hdaudioC0D0: ALC1200: SKU not ready 0x411111f0
>> [ 11.240014] sound hdaudioC0D0: autoconfig: line_outs=4
>> (0x14/0x15/0x16/0x17/0x0) type:line
>> [ 11.240019] sound hdaudioC0D0: speaker_outs=0
>> (0x0/0x0/0x0/0x0/0x0)
>> [ 11.240023] sound hdaudioC0D0: hp_outs=1 (0x1b/0x0/0x0/0x0/0x0)
>> [ 11.240026] sound hdaudioC0D0: mono: mono_out=0x0
>> [ 11.240029] sound hdaudioC0D0: dig-out=0x1e/0x0
>> [ 11.240032] sound hdaudioC0D0: inputs:
>> [ 11.240036] sound hdaudioC0D0: Front Mic=0x19
>> [ 11.240039] sound hdaudioC0D0: Rear Mic=0x18
>> [ 11.240042] sound hdaudioC0D0: Line=0x1c
>> [ 11.240045] sound hdaudioC0D0: dig-in=0x1f
>> [ 11.277297] wm8775 0-001b: chip found @ 0x36 (ivtv i2c driver #0)
>> [ 11.453206] ieee80211 phy0: rt2x00_set_chip: Info - Chipset detected
>>
>> - rt: 2573, rf: 0002, rev: 000a
>> [ 11.518256] ieee80211 phy0: Selected rate control algorithm
>> 'minstrel_ht'
>> [ 11.518983] usbcore: registered new interface driver rt73usb
>> [ 11.582579] tuner-simple 0-0061: creating new instance
>> [ 11.582583] tuner-simple 0-0061: type set to 56 (Philips PAL/SECAM
>> multi (FQ1216AME MK4))
>> [ 11.584860] ivtv0: Registered device video0 for encoder MPG (4096
>> kB)
>> [ 11.584899] ivtv0: Registered device video32 for encoder YUV (2048
>> kB)
>> [ 11.584935] ivtv0: Registered device vbi0 for encoder VBI (1024 kB)
>> [ 11.584969] ivtv0: Registered device video24 for encoder PCM (320
>> kB)
>> [ 11.585002] ivtv0: Registered device radio0 for encoder radio
>> [ 11.585004] ivtv0: Initialized card: Hauppauge WinTV PVR-150
>> [ 11.585049] ivtv: End initialization
>>
>>
>> _______________________________________________
>> ivtv-users mailing list
>> ivtv-users@ivtvdriver.org
>> http://ivtvdriver.org/mailman/listinfo/ivtv-users
> First check the source code against the WM8775 datasheet to see if your hypothesis may be correct:
>
> http://dl.ivtvdriver.org/datasheets/audio/WM8775.pdf
>
> http://lxr.free-electrons.com/source/drivers/media/i2c/wm8775.c
>
> The pvr150 follows the code branches marked "!is_nova_s".
>
> I'm on the road, so I didn't see limiting when glancing on my tiny phone.
>
> Regards,
> Andy
Thanks Andy,
Yes, looking at the source I think that changing the "loudness" setting
via v4l2-ctl toggles the AGC circuit on and off, but if it is on it is
always doing automatic levelling, not limiting. After some more testing
I think my problem was actually that I was overloading the input to the
card, in which case I must have been mistaken about getting undistorted
audio when I set a low "volume" with v4l2-ctl.

Sorry for the noise,
Alister

_______________________________________________
ivtv-users mailing list
ivtv-users@ivtvdriver.org
http://ivtvdriver.org/mailman/listinfo/ivtv-users