I like to keep my headphones plugged in, then depending on the situation just switch the audio output as needed. I'm easily able to do this in Windows - my headphones and speakers show up as different devices, and I'm able to switch.
In Ubuntu (Kubuntu 18.04) I can't seem to get this to work. After some fiddling, I found that I can disable Automute in alsamixer, and that way I can have sound coming from both speakers and headphones, but I still can't find a way to choose between them. Pulse audio and the kde settings only show one device (Built-in Audio Analog Stereo).
Edit: I was thinking I could probably keep the headphones plugged in, and use a script to enable/disable automute depending on whether I want to listen to headphones/speakers. But this doesn't work because with automute disabled the speaker volume is way lower.
Edit: output of aplay -l
as requested:
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC1220 Analog [ALC1220 Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 1: ALC1220 Digital [ALC1220 Digital]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: GoMic [Samson GoMic], device 0: USB Audio [USB Audio]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 7: HDMI 1 [HDMI 1]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 8: HDMI 2 [HDMI 2]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 9: HDMI 3 [HDMI 3]
Subdevices: 1/1
Subdevice #0: subdevice #0
apt-get install pavucontrol
– cmak.fr May 25 '18 at 08:30