Bug 90496 - Feature request: add Auto-mute tumbler
Summary: Feature request: add Auto-mute tumbler
Status: RESOLVED MOVED
Alias: None
Product: PulseAudio
Classification: Unclassified
Component: pavucontrol (show other bugs)
Version: unspecified
Hardware: Other All
: medium enhancement
Assignee: pulseaudio-bugs
QA Contact: pulseaudio-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-17 20:01 UTC by Yan Pas
Modified: 2018-07-30 09:30 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yan Pas 2015-05-17 20:01:37 UTC
I don't know how to disable auto-muting rear output when I plug in front output. I'm sure there is a way to do it via console, but there should be graphical tick. Qasmixer has this feature
Comment 1 Raymond 2015-05-25 06:59:36 UTC
disable auto mute control only affect driver and have no effect on pulseaudio  since switch-on-port-avaialable use jack detection control to switch between ports 

in theory, you have to disable jack detection of analog codec of snd-hda-intel by hint jac_detect = no with  early patching


https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/tree/Documentation/sound/alsa/HD-Audio.txt

ck detection control, the available of speaker, line out and headphone ports are all unknown
Comment 2 Yan Pas 2015-05-25 08:44:18 UTC
But QAsMixer has this feature. What does it do:
If you untick automute - when you plug headphones to front panel, sound from rear is not muted and still plays. If automute enabled and you plug headphone to front panel - it is possible to raise loudness of rear speaker via simple alsa-mixer
Or it is too low level feature for Pulse?
Comment 3 Raymond 2015-05-25 12:07:39 UTC
You have to post pulseaudio verbose log


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

dBmin of those playback volume controls are -64dB

virtual master playback volume is present on both headphone path and line out path

it depend on pulseaudio adjust which volume control first 

http://cgit.freedesktop.org/pulseaudio/pulseaudio/tree/src/modules/alsa/mixer/paths

you can try comment volume of  [Element Master]  from headphones.conf and lineout.conf  and observe the difference


[Element Master]
switch = mute
#volume = merge
override-map.1 = all
override-map.2 = all-left,all-right


ALC892 is a 10 channel HDA codec which support 7.1+2 multistreaming



Card hw:0 'SB'/'HDA ATI SB at 0xfbcf8000 irq 16'
  Mixer name	: 'Realtek ALC892'
  Components	: 'HDA:10ec0892,18490892,00100302'
  Controls      : 49
  Simple ctrls  : 21
Simple mixer control 'Master',0
  Capabilities: pvolume pvolume-joined pswitch pswitch-joined
  Playback channels: Mono
  Limits: Playback 0 - 64
  Mono: Playback 37 [58%] [-27.00dB] [on]
Simple mixer control 'Headphone',0
  Capabilities: pvolume pswitch
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 64
  Mono:
  Front Left: Playback 64 [100%] [0.00dB] [on]
  Front Right: Playback 64 [100%] [0.00dB] [on]
Simple mixer control 'PCM',0
  Capabilities: pvolume
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 255
  Mono:
  Front Left: Playback 255 [100%] [0.00dB]
  Front Right: Playback 255 [100%] [0.00dB]
Simple mixer control 'Front',0
  Capabilities: pvolume pswitch
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 64
  Mono:
  Front Left: Playback 64 [100%] [0.00dB] [on]
  Front Right: Playback 64 [100%] [0.00dB] [on]

Simple mixer control 'Surround',0
  Capabilities: pvolume pswitch
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 64
  Mono:
  Front Left: Playback 64 [100%] [0.00dB] [on]
  Front Right: Playback 64 [100%] [0.00dB] [on]
Simple mixer control 'Center',0
  Capabilities: pvolume pvolume-joined pswitch pswitch-joined
  Playback channels: Mono
  Limits: Playback 0 - 64
  Mono: Playback 64 [100%] [0.00dB] [on]
Simple mixer control 'LFE',0
  Capabilities: pvolume pvolume-joined pswitch pswitch-joined
  Playback channels: Mono
  Limits: Playback 0 - 64
  Mono: Playback 64 [100%] [0.00dB] [on]
Simple mixer control 'Side',0
  Capabilities: pvolume pswitch
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 64
  Mono:
  Front Left: Playback 64 [100%] [0.00dB] [on]
  Front Right: Playback 64 [100%] [0.00dB] [on]
Comment 4 Raymond 2015-05-25 13:22:54 UTC
you need to comment the following if you want to disable pulseaudio 's  auto mute

http://cgit.freedesktop.org/pulseaudio/pulseaudio/plain/src/modules/alsa/mixer/paths/analog-output-headphones.conf

[Element Rear]
switch = off
volume = off

[Element Surround]
switch = off
volume = off

[Element Side]
switch = off
volume = off

[Element Center]
switch = off
volume = off

[Element LFE]
switch = off
volume = off


http://cgit.freedesktop.org/pulseaudio/pulseaudio/plain/src/modules/alsa/mixer/paths/analog-output-lineout.conf


[Element Headphone]
switch = off
volume = off
Comment 5 Yan Pas 2015-05-25 13:52:22 UTC
Got it. Could you transform this bug to enhancement? I would like to see this feature in pavucontrol
Comment 6 Raymond 2015-05-26 02:37:00 UTC
the problem is some hda codec alc662 ,...with three jack at rear panel,  front playback volume control is shared with green line out jack and headphone


; On some machines Front is actually a part of the Headphone path
[Element Front]
switch = mute
volume = zero
Comment 7 Jarno Suni 2015-05-27 17:18:05 UTC
How about independent volume control for headphones and separate line out (or internal speaker)?
Comment 8 Yan Pas 2015-05-27 18:38:52 UTC
This is good too.
Comment 9 Raymond 2015-05-28 14:00:37 UTC
(In reply to Jarno Suni from comment #7)
> How about independent volume control for headphones and separate line out
> (or internal speaker)?

it is not easy to skip the virtual master playback volume in pa_alsa_path_set_volume
just skip element_set_volume when the element name is Master , mono and driver is snd-hda-intel

however some hda codecs does not has hardware mute switch

you can add pa_log_info in element_ser_volume of  alsa-mixer.c to find out which controls( master or headphone/line out playback volume) are first used by pulseaudio port 's path
Comment 10 GitLab Migration User 2018-07-30 09:30:47 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/pulseaudio/pavucontrol/issues/37.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.