Pulseaudio does not recognize sound levels correctly.

Bug #1210129 reported by Kamil Jakubowski
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
PulseAudio
Fix Released
Medium
alsa-driver (Ubuntu)
Fix Released
Undecided
Unassigned
pulseaudio (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

When I am setting volume to 75-100% sounds is amplified and quality is very bad.
Setting for "Unampified" in sound settings (which is placed around 50% of the bar) makes sound is almost unhearable.

Sound is good and loud around 60% of volume. This is really annoying because setting volume from keyboard or sound indicator is useless -> volume up makes terrible sound, volume down only 10% to 50%(unamplified) makes there is almost no sound.

ProblemType: Bug
DistroRelease: Ubuntu 13.04
Package: pulseaudio 1:3.0-0ubuntu6
ProcVersionSignature: Ubuntu 3.8.0-27.40-generic 3.8.13.4
Uname: Linux 3.8.0-27-generic i686
ApportVersion: 2.9.2-0ubuntu8.1
Architecture: i386
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: ciastek 2109 F.... pulseaudio
 /dev/snd/pcmC0D0p: ciastek 2109 F...m pulseaudio
Date: Thu Aug 8 15:18:41 2013
InstallationDate: Installed on 2013-06-12 (56 days ago)
InstallationMedia: Ubuntu 13.04 "Raring Ringtail" - Release i386 (20130424)
MarkForUpload: True
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 LANG=pl_PL.UTF-8
 SHELL=/bin/bash
PulseList:
 Error: command ['pacmd', 'list'] failed with exit code 1: Home directory not accessible: Permission denied
 No PulseAudio daemon running, or not running as session daemon.
SourcePackage: pulseaudio
Symptom: audio
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 06/11/2008
dmi.bios.vendor: Phoenix Technologies, LTD
dmi.bios.version: ASUS P5N73-AM ACPI BIOS Revision 0201
dmi.board.name: P5N73-AM
dmi.board.vendor: ASUSTeK Computer INC.
dmi.board.version: 2.XX
dmi.chassis.asset.tag: 123456789000
dmi.chassis.type: 3
dmi.chassis.vendor: Chassis Manufacture
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnPhoenixTechnologies,LTD:bvrASUSP5N73-AMACPIBIOSRevision0201:bd06/11/2008:svnSystemmanufacturer:pnSystemProductName:pvrSystemVersion:rvnASUSTeKComputerINC.:rnP5N73-AM:rvr2.XX:cvnChassisManufacture:ct3:cvrChassisVersion:
dmi.product.name: System Product Name
dmi.product.version: System Version
dmi.sys.vendor: System manufacturer

Revision history for this message
In , Agustin-6 (agustin-6) wrote :

Created attachment 66151
x = alsamixer pecentage for the PCM control. y = corresponding volume in dB.

I have an ASUS P5KPL-1600 motherboard with a VIA VT1708B 8-Ch chip managed by snd-hda-intel. The volume control in pavucontrol, Gnome's sound preferences and all apps with flat-volume enabled is too non-lineal and just plain wrong.

alsamixer has two useful controls for output volume:
PCM: goes from -40.25dB in 0% through 0dB in 53% to 14dB (*with clipping*) in 100%. (This is not linear at all, see graph.png, attached.)
Master: goes from 0dB in 0% (very quiet output) to 6.75dB (without any clipping, loud and clear) in 100% with 0.25dB = 3.75% increments.

When, in PulseAudio 2.1, I set the volume in 100% it maxes out both PCM and Master, so I get a quite distorted sound. This is expected, but the scale is wrong: 100% is 0dB but it should be 14dB.

The base should be at -14dB, or 58%, when PCM is at 0dB (53%) and Master at 6.75dB (100%), but it is at -20.75dB (45%), with Master and PCM at 0dB, with very quiet output. The difference in sound pressure between 45% and 53% is very large.

Between -20.75dB (45%) and -68dB (7%) the volume does not change at all. All controls in alsamixer remain the same.

Between -68dB (7%) and -108.24dB (2%) the PCM control goes down to zero, and any less than that results in muted output.

This behaviour is quite strange and I don't know how much of it is pulseaudio's fault, how much is the alsa driver's and how much is mine.

Thanks.

Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :
Revision history for this message
Raymond (superquad-vortex2) wrote :

the pcm playback volume control at audio mixer 0x16 has different dB range and is common to headphone and line out, this mean that virtual master should not use is as slave

use alsamixer -c0 to monitor the change in volume controls when you change the slider in sound preference

Simple mixer control 'Master',0
  Capabilities: pvolume pvolume-joined pswitch pswitch-joined penum
  Playback channels: Mono
  Limits: Playback 0 - 27
  Mono: Playback 27 [100%] [6.75dB] [on]
Simple mixer control 'Headphone',0
  Capabilities: pvolume pswitch penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 27
  Mono:
  Front Left: Playback 27 [100%] [0.00dB] [on]
  Front Right: Playback 27 [100%] [0.00dB] [on]
Simple mixer control 'PCM',0
  Capabilities: pvolume pswitch penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 31
  Mono:
  Front Left: Playback 24 [77%] [1.75dB] [on]
  Front Right: Playback 24 [77%] [1.75dB] [on]
Simple mixer control 'Front',0
  Capabilities: pvolume pswitch penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 27
  Mono:
  Front Left: Playback 27 [100%] [0.00dB] [on]
  Front Right: Playback 27 [100%] [0.00dB] [on]

Revision history for this message
Raymond (superquad-vortex2) wrote :

post the pulseaudio verbose log

http://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/hda_generic.c?id=352f7f914ebb8fe19f9b3f03e7767b04eedf5be3

static int build_loopback_controls(struct hda_codec *codec)
+
+/* slave controls for virtual master */
+static const char * const slave_pfxs[] = {
+ "Front", "Surround", "Center", "LFE", "Side",
+ "Headphone", "Speaker", "Mono", "Line Out",
+ "CLFE", "Bass Speaker", "PCM",
+ NULL,
+};

 control.1 {
  iface MIXER
  name 'Front Playback Volume'
  value.0 27
  value.1 27
  comment {
   access 'read write'
   type INTEGER
   count 2
   range '0 - 27'
   dbmin -4725
   dbmax 0
   dbvalue.0 0
   dbvalue.1 0
  }
 }

 control.3 {
  iface MIXER
  name 'Surround Playback Volume'
  value.0 27
  value.1 27
  comment {
   access 'read write'
   type INTEGER
   count 2
   range '0 - 27'
   dbmin -4725
   dbmax 0
   dbvalue.0 0
   dbvalue.1 0
  }
 }

 control.5 {
  iface MIXER
  name 'Center Playback Volume'
  value 27
  comment {
   access 'read write'
   type INTEGER
   count 1
   range '0 - 27'
   dbmin -4725
   dbmax 0
   dbvalue.0 0
  }
 }

 control.7 {
  iface MIXER
  name 'LFE Playback Volume'
  value 27
  comment {
   access 'read write'
   type INTEGER
   count 1
   range '0 - 27'
   dbmin -4725
   dbmax 0
   dbvalue.0 0
  }
 }

 control.9 {
  iface MIXER
  name 'Side Playback Volume'
  value.0 27
  value.1 27
  comment {
   access 'read write'
   type INTEGER
   count 2
   range '0 - 27'
   dbmin -4725
   dbmax 0
   dbvalue.0 0
   dbvalue.1 0
  }
 }

 control.11 {
  iface MIXER
  name 'PCM Playback Volume'
  value.0 24
  value.1 24
  comment {
   access 'read write'
   type INTEGER
   count 2
   range '0 - 31'
   dbmin -4025
   dbmax 1400
   dbvalue.0 175
   dbvalue.1 175
  }
 }

 control.13 {
  iface MIXER
  name 'Headphone Playback Volume'
  value.0 27
  value.1 27
  comment {
   access 'read write'
   type INTEGER
   count 2
   range '0 - 27'
   dbmin -4725
   dbmax 0
   dbvalue.0 0
   dbvalue.1 0
  }
 }

Changed in pulseaudio (Ubuntu):
status: New → Incomplete
Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

Sorry for delay in response, I was offline.

I was monitoring values in alsa mixer, and this is a result:

1) "The place" in the bar then sound is good quality and able to hear is on first image of the screenshot
With Master - 100%
PCM 50-60%

2) When reduce volume to Unamplified ("Bez wzmocnienia") Master falls almost to zero. Thats why sound is very very quiet. Below unamplified master goes to 0. - image 2 on the screenshot

3) on 100% of volume bar Master and PCM are 100% and sound is terrible - image 3 on screenshot

>>> post the pulseaudio verbose log
>>> http://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/hda_generic.c?id=352f7f914ebb8fe19f9b3f03e7767b04eedf5be3

I do not know how to use it to generate a log. Please help.

Thanks in advance.

Revision history for this message
Raymond (superquad-vortex2) wrote :

https://wiki.ubuntu.com/PulseAudio/Log

since pcm playback volume has a 14dB gain

do you mean that you have distorted sound when pcm playback volume is over 0dB ?

control.11 {
   iface MIXER
   name 'PCM Playback Volume'
   value.0 24
   value.1 24
   comment {
    access 'read write'
    type INTEGER
    count 2
    range '0 - 31'
    dbmin -4025
    dbmax 1400
    dbvalue.0 175
    dbvalue.1 175
   }
  }

Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

I do not know how many PCM dB is when sound is getting distorted - but it is more that 50 (is this %? ) in unit which is presented in alsamixer below the bar.

I cannot generate the log because I have not ~/.pulse dir in my Homedir, so I can set autospawn = no.
Should I seek it in /etc or /usr (somewhere)

?

Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

so I can not set *

Revision history for this message
Raymond (superquad-vortex2) wrote :

open terminal and run alsamixer -c0 to monitor the dB OF PCM PLAYBACK VOLUME CONTROL by using right arrow to select pcm playback volume when you change the slider of sound preference

Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

Thank you for your tip, I missed '-c0' argument earlier.

Yes, sound begins distorted over PCM [dB gain: 0,00, 0,00].

Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

Hmm, but that argument chooses a card number, nothing changes in display. So I had not seen label with dB earlier. Sorry ;-)

Revision history for this message
Raymond (superquad-vortex2) wrote :

you have to provide pulseaudio log, in theory spend preference sGould provide a mark at the slider for 0dB

https://bugs.freedesktop.org/show_bug.cgi?id=54096

the alternative is to limit the maximum dB of pcm playback volume control to 0dB instead of 14dB

Changed in pulseaudio:
importance: Unknown → Medium
status: Unknown → Confirmed
Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

This is what was generated:

( 0.000| 0.000) I: [pulseaudio] main.c: setrlimit(RLIMIT_NICE, (31, 31)) failed: Operation not permitted
( 0.000| 0.000) I: [pulseaudio] main.c: setrlimit(RLIMIT_RTPRIO, (9, 9)) failed: Operation not permitted
( 0.000| 0.000) D: [pulseaudio] core-rtclock.c: Timer slack is set to 50 us.
( 0.008| 0.008) D: [pulseaudio] core-util.c: RealtimeKit worked.
( 0.008| 0.000) I: [pulseaudio] core-util.c: Successfully gained nice level -11.
( 0.008| 0.000) I: [pulseaudio] main.c: This is PulseAudio 3.0
( 0.008| 0.000) D: [pulseaudio] main.c: Compilation host: i686-pc-linux-gnu
( 0.008| 0.000) D: [pulseaudio] main.c: Compilation CFLAGS: -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -Wextra -pipe -Wno-long-long -Wno-overlength-strings -Wunsafe-loop-optimizations -Wundef -Wformat=2 -Wlogical-op -Wsign-compare -Wformat-security -Wmissing-include-dirs -Wformat-nonliteral -Wpointer-arith -Winit-self -Wdeclaration-after-statement -Wfloat-equal -Wmissing-prototypes -Wredundant-decls -Wmissing-declarations -Wmissing-noreturn -Wshadow -Wendif-labels -Wcast-align -Wstrict-aliasing -Wwrite-strings -Wno-unused-parameter -ffast-math -Wp,-D_FORTIFY_SOURCE=2 -fno-common -fdiagnostics-show-option
( 0.008| 0.000) D: [pulseaudio] main.c: Running on host: Linux i686 3.8.0-29-generic #42-Ubuntu SMP Tue Aug 13 23:12:18 UTC 2013
( 0.008| 0.000) D: [pulseaudio] main.c: Found 2 CPUs.
( 0.009| 0.000) I: [pulseaudio] main.c: Page size is 4096 bytes
( 0.009| 0.000) D: [pulseaudio] main.c: Compiled with Valgrind support: no
( 0.009| 0.000) D: [pulseaudio] main.c: Running in valgrind mode: no
( 0.009| 0.000) D: [pulseaudio] main.c: Running in VM: no
( 0.009| 0.000) D: [pulseaudio] main.c: Optimized build: yes
( 0.009| 0.000) D: [pulseaudio] main.c: FASTPATH defined, only fast path asserts disabled.
( 0.009| 0.000) I: [pulseaudio] main.c: Machine ID is d9cdbce1099ab3c36cb0ccfb51b8f45c.
( 0.009| 0.000) I: [pulseaudio] main.c: Using runtime directory /run/user/ciastek/pulse.
( 0.009| 0.000) I: [pulseaudio] main.c: Using state directory /home/ciastek/.config/pulse.
( 0.009| 0.000) I: [pulseaudio] main.c: Using modules directory /usr/lib/pulse-3.0/modules.
( 0.009| 0.000) I: [pulseaudio] main.c: Running in system mode: no
( 0.009| 0.000) E: [pulseaudio] pid.c: Daemon already running.
( 0.009| 0.000) E: [pulseaudio] main.c: pa_pid_file_create() failed.

Revision history for this message
Raymond (superquad-vortex2) wrote :

0.009| 0.000) E: [pulseaudio] pid.c: Daemon already running.

did you follow the instruction to disable autospwan and kill pulseaudio

 pulseaudio -vvvvv and change the slider in sound preference from Max to min

and provide log similar to Symptom_PulseAudioLog.txt in https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/1207808e

Revision history for this message
In , Raymond (superquad-vortex2) wrote :

you have to provide pulseaudio verbose log to show how pulseaidiot caluclate dB when request volume from 100% to 0%

Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.204| 9.204) [pulseaudio] protocol-native.c: Client indicator-sound-service changes volume of sink alsa_output.pci-0000_00_1b.0.analog-stereo.
Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.205| 0.000) [alsa-sink] alsa-sink.c: Requested volume: 0: 99% 1: 99%
Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.205| 0.000) [alsa-sink] alsa-sink.c: in dB: 0: -0.18 dB 1: -0.18 dB
Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.205| 0.000) [alsa-sink] alsa-sink.c: Got hardware volume: 0: 100% 1: 100%
Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.205| 0.000) [alsa-sink] alsa-sink.c: in dB: 0: 0.00 dB 1: 0.00 dB
Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.205| 0.000) [alsa-sink] alsa-sink.c: Calculated software volume: 0: 99% 1: 99% (accurate-enough=yes)
Aug 2 19:08:44 encke pulseaudio[2207]: ( 9.205| 0.000) [alsa-sink] alsa-sink.c: in dB: 0: -0.18 dB 1: -0.18 dB

Revision history for this message
In , Agustin-6 (agustin-6) wrote :

Thanks for taking a look at this, it has been fixed (perhaps inadvertently) since I reported it.

Have a good day.

Changed in pulseaudio:
status: Confirmed → Fix Released
Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

In my case the same - Ii looks that it has been fixed. (Although I did not remember any update - but I might miss that because I call updates automatically when they appear).
Now on 100% of volume I have 100% of Master and 100% of PCM, and PCM on 100% has only 1,75dB gain. And on 100% it makes good sound.

But I have another problem now - "jumps" in volume up/volume down.

When I have 100% of volume bar (in sound indicator) I have Master: 100%(.75dB), PCM 100% (1.75db). Only one step down by keyboard Volume- button makes sound a lot of quieter ("jumps" are like 5-6% of the all volume bar) - then Master: 78%(5.25), PCM: 92% (0.00)
next step down -> Master 48%(3.25), PCM 92%
next -> Master 19%, PCM 92% (and there is almost no sound - although volume bar on indicator is already on 70-75%)
next -> Master 0% - no sound
next steps only "Front" in alsa mixer, but it makes no change in 0-70% interval - there is simply no sound.

I'm sending Pulselog (with changing volume from max to min while logging - as you said).

Revision history for this message
Raymond (superquad-vortex2) wrote :

can you provide the values when request volume is 100% ?

124| 0.000) D: [alsa-sink] alsa-sink.c: Requested volume: 0: 94% 1: 94%
( 5.124| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: -1.61 dB 1: -1.61 dB
( 5.124| 0.000) D: [alsa-sink] alsa-sink.c: Got hardware volume: 0: 100% 1: 100%
( 5.124| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: 0.00 dB 1: 0.00 dB
( 5.124| 0.000) D: [alsa-sink] alsa-sink.c: Calculated software volume: 0: 94% 1: 94% (accurate-enough=no)
( 5.124| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: -1.61 dB 1: -1.61 dB
( 5.124| 0.000) D: [alsa-sink] sink.c: Volume not changing

when pulseaudio set software volume to -inf dB, does it really need to set headwaters volume to -inf dB ?

the playback switch mute is equivalent to -inf dB

   6.086| 0.000) D: [alsa-sink] alsa-sink.c: Requested volume: 0: 0% 1: 0%
( 6.086| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: -inf dB 1: -inf dB
( 6.086| 0.000) D: [alsa-sink] alsa-sink.c: Got hardware volume: 0: 3% 1: 3%
( 6.086| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: -96.00 dB 1: -96.00 dB
( 6.086| 0.000) D: [alsa-sink] alsa-sink.c: Calculated software volume: 0: 0% 1: 0% (accurate-enough=no)
( 6.086| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: -inf dB 1: -inf dB
( 6.086| 0.000) D: [alsa-sink] sink.c: Volume going down to 0 at 3200829567
( 6.086| 0.000) D: [alsa-sink] sink.c: Volume change to 0 at 3200829567 was written 37 usec late
( 6.087| 0.000) D: [alsa-sink] alsa-sink.c: Written HW volume did not match with the request: 0: 0% 1: 0% (request) != 0: 3% 1: 3%
( 6.087| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: -inf dB 1: -inf dB (request) != 0: -96.00 dB 1: -96.00 dB

Revision history for this message
Raymond (superquad-vortex2) wrote :

>Now on 100% of volume I have 100% of Master and 100% of PCM, and PCM on 100% has only 1,75dB gain. And on 100% it makes good sound.

you have to post the output of alsa-info.sh

http://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/log/sound/pci/hda/hda_generic.c

http://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/log/sound/pci/hda/patch_via.c

there is no change in limiting dB / VOLUME range for vt1708b

Revision history for this message
Raymond (superquad-vortex2) wrote :
Download full text (4.3 KiB)

you have to ask pulseaudio developer how to calculate -87.5dB and 8.5dB, why 0 to 27 steps ?

 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Path analog-output (Analog Output), direction=1, priority=99, probed=yes, supported=yes, has_mute=yes, has_volume=yes, has_dB=yes, min_volume=0, max_volume=27, min_dB=-87.5, max_dB=8.5
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Master, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x7ffffffffffff, n_channels=1, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Headphone, direction=1, switch=1, volume=3, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x6, n_channels=2, override_map=no
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Front, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x6, n_channels=2, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Surround, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x60, n_channels=2, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Side, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0xc00, n_channels=2, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Center, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x4900000000018, n_channels=1, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element LFE, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x80, n_channels=1, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element PCM, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x3600000000f66, n_channels=2, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element IEC958, direction=1, switch=2, volume=0, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x0, n_channels=0, override_map=no
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Path analog-output-headphones (Headphones), direction=1, priority=90, probed=yes, supported=yes, has_mute=yes, has_volume=yes, has_dB=yes, min_volume=0, max_volume=27, min_dB=-87.5, max_dB=8.5
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Master, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=0, required_absent=0, mask=0x7ffffffffffff, n_channels=1, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Headphone, direction=1, switch=1, volume=1, volume_limit=-1, enumeration=0, required=0, required_any=4, required_absent=0, mask=0x3600000000f66, n_channels=2, override_map=yes
( 0.071| 0.000) D: [pulseaudio] alsa-mixer.c: Element Front, direction=1, switch=1, volume=3, volume_limit=-1, enumeration=0, required=0, required_any=0, r...

Read more...

Changed in pulseaudio (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

Values for 100%:
( 27.898| 0.000) D: [alsa-sink] alsa-sink.c: Requested volume: 0: 100% 1: 100%
( 27.898| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: 0.00 dB 1: 0.00 dB
( 27.898| 0.000) D: [alsa-sink] alsa-sink.c: Got hardware volume: 0: 100% 1: 100%
( 27.898| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: 0.00 dB 1: 0.00 dB
( 27.898| 0.000) D: [alsa-sink] alsa-sink.c: Calculated software volume: 0: 100% 1: 100% (accurate-enough=yes)
( 27.898| 0.000) D: [alsa-sink] alsa-sink.c: in dB: 0: 0.00 dB 1: 0.00 dB
( 27.898| 0.000) D: [alsa-sink] sink.c: Volume not changing
( 27.898| 0.000) I: [pulseaudio] module-device-restore.c: Storing volume/mute for device+port sink:alsa_output.pci-0000_00_09.0.analog-stereo:analog-output.

>>>>when pulseaudio set software volume to -inf dB, does it really need to set headwaters volume to -inf dB ?
>>>>the playback switch mute is equivalent to -inf dB

I do not understand what I should do with it?

>>>> you have to post the output of alsa-info.sh
With of the flags I should use?
Available options:
 --with-aplay (includes the output of aplay -l)
 --with-amixer (includes the output of amixer)
 --with-alsactl (includes the output of alsactl)
 --with-configs (includes the output of ~/.asoundrc and
     /etc/asound.conf if they exist)
 --with-devices (shows the device nodes in /dev/snd/)
 --with-dmesg (shows the ALSA/HDA kernel messages)

>>>> you have to ask pulseaudio developer how to calculate -87.5dB and 8.5dB, why 0 to 27 steps ?
I do not clearly understand what I should do.

Revision history for this message
Raymond (superquad-vortex2) wrote :

there are two amp at node 0x16 and 0x1a in green line out Jack path from node 0x10 to node 0x1a

dB range is sum of pcm playback volume and front playback volume

not sure why pulseaudio use 8.5dB as Max since dB Max of pcm playback volume is 14 dB

Node 0x16 [Audio Mixer] wcaps 0x20050b: Stereo Amp-In
  Control: name="PCM Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=0, ofs=0
  Control: name="PCM Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=0, ofs=0
  Control: name="Rear Mic Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=2, ofs=0
  Control: name="Rear Mic Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=2, ofs=0
  Control: name="Front Mic Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=4, ofs=0
  Control: name="Front Mic Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=4, ofs=0
  Control: name="Line Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=3, ofs=0
  Control: name="Line Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=3, ofs=0
  Control: name="CD Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=1, ofs=0
  Control: name="CD Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=1, ofs=0
  Amp-In caps: ofs=0x17, nsteps=0x1f, stepsize=0x06, mute=1
  Amp-In vals: [0x18 0x18] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80]
  Power states: D0 D1 D2 D3
  Power: setting=D0, actual=D0
  Connection: 6
     0x10 0x1f 0x1a 0x1b 0x1e 0x25

Node 0x1c [Pin Complex] wcaps 0x40058d: Stereo Amp-Out
  Control: name="Front Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Control: name="Front Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Control: name="Line Out Front Jack", index=0, device=0
  Amp-Out caps: ofs=0x1b, nsteps=0x1b, stepsize=0x06, mute=1
  Amp-Out vals: [0x1b 0x1b]
  Pincap 0x0000001c: OUT HP Detect
  Pin Default 0x01014010: [Jack] Line Out at Ext Rear
    Conn = 1/8, Color = Green
    DefAssociation = 0x1, Sequence = 0x0
  Pin-ctls: 0x40: OUT
  Unsolicited: tag=02, enabled=1
  Power states: D0 D1 D2 D3
  Power: setting=D0, actual=D0
  Connection: 1
     0x16
Node 0x1d [Pin Complex] wcaps 0x40058d: Stereo Amp-Out
  Control: name="Headphone Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Control: name="Headphone Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Control: name="Independent HP", index=0, device=0
  Control: name="Front Headphone Jack", index=0, device=0
  Amp-Out caps: ofs=0x1b, nsteps=0x1b, stepsize=0x06, mute=1
  Amp-Out vals: [0x1b 0x1b]
  Pincap 0x0000001c: OUT HP Detect
  Pin Default 0x0221401f: [Jack] HP Out at Ext Front
    Conn = 1/8, Color = Green
    DefAssociation = 0x1, Sequence = 0xf
  Pin-ctls: 0xc0: OUT HP
  Unsolicited: tag=01, enabled=1
  Power states: D0 D1 D2 D3
  Power: setting=D0, actual=D0
  Connection: 2
     0x16* 0x25

Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

Is there something else that I can do or post to fix this bug?

Revision history for this message
Raymond (superquad-vortex2) wrote :

has_dB=yes, min_volume=0, max_volume=27, min_dB=-87.5, max_dB=8.5

have you ask the pulseaudio developer how to calculate Max_dB ?

min_dB=-87.5 = (-47.25) + (-40.45) = front + pcm

http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss

Revision history for this message
Raymond (superquad-vortex2) wrote :

-40.25 + (31 * 1.75) = 14

-40.25 + (27 * 1.75) = 7

how pulseaudio obtain max_dB=8.5 ?

Revision history for this message
Raymond (superquad-vortex2) wrote :

send email to alsa developer to ask why virtual master dB MIN IS 0dB when the slaves have negative dB

and dBMAX IS 6.75dB

http://www.alsa-project.org/mailman/listinfo/alsa-devel

control.36 {
  iface MIXER
  name 'Master Playback Volume'
  value 27
  comment {
   access 'read write'
   type INTEGER
   count 1
   range '0 - 27'
   dbmin 0
   dbmax 675
   dbvalue.0 675
  }
 }

Revision history for this message
Raymond (superquad-vortex2) wrote :

try latest alsa-driver

https://wiki.ubuntu.com/Audio/UpgradingAlsa/DKMS

PCM playback volume control has been deleted from node 0x16 and the amp -in values set to 0dB [0x17 0x17]

Node 0x16 [Audio Mixer] wcaps 0x20050b: Stereo Amp-In
  Control: name="Rear Mic Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=2, ofs=0
  Control: name="Rear Mic Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=2, ofs=0
  Control: name="Front Mic Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=4, ofs=0
  Control: name="Front Mic Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=4, ofs=0
  Control: name="Line Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=3, ofs=0
  Control: name="Line Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=3, ofs=0
  Control: name="CD Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=1, ofs=0
  Control: name="CD Playback Switch", index=0, device=0
    ControlAmp: chs=3, dir=In, idx=1, ofs=0
  Amp-In caps: ofs=0x17, nsteps=0x1f, stepsize=0x06, mute=1
  Amp-In vals: [0x17 0x17] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80] [0x80 0x80]
  Power states: D0 D1 D2 D3
  Power: setting=D0, actual=D0
  Connection: 6
     0x10 0x1f 0x1a 0x1b 0x1e 0x25

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in alsa-driver (Ubuntu):
status: New → Confirmed
Revision history for this message
Kamil Jakubowski (kamil-jakubowski) wrote :

I want to note that update to the latest alsa-driver have fixed all my problems.

Now sound is good in all scale 0-100%, and scale is proportionally - on 10% I have very quiet sound, and on 100% I have 100% loud volume that is not distorted (0dB gain on master and PCM)

Thank you @Raymond for your help!

Changed in alsa-driver (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Thank you for reporting this bug to Ubuntu.
Ubuntu 13.04 (raring) reached end-of-life on January 27, 2014.

See this document for currently supported Ubuntu releases:
https://wiki.ubuntu.com/Releases

We appreciate that this bug may be old and you might not be interested in discussing it any more. But if you are then please upgrade to the latest Ubuntu version and re-test.

Changed in pulseaudio (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Based on comment #29 I'm assuming this is closed.

Changed in pulseaudio (Ubuntu):
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.