Kde hdmi sound output

I’ve got a laptop with an HDMI output. When I connect a display I get a nice popup to let me choose to extend / mirror / ignore that display output device.

But I can’t see anything about that HDMI output device in my KDE audio-config GUI.

After googling a bit I found here, that I can list audio output devices like this:

$aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC3266 Analog [ALC3266 Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [VSX-924]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 9: HDMI 3 [HDMI 3]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 10: HDMI 4 [HDMI 4]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

And that this produces white noise on each of the 8 channels of the connected surround system:

speaker-test -D hw:0,8 -c 8 

Now how can I continue from here to stream “normal” audio output to that device, preferable by making that output select-able & configurable through the “normal” KDE audio config GUI.

That stackoverflow answer says to create a .asoundrc config file, so I’ll next try to research what to put in there, the target path seems to be ~/.asoundrc.

UPDATE: okey so this allows me to pass stereo sound through hdmi:

pactl load-module module-alsa-sink device=hw:0,8

next step: find out how I can name that device (it reads “Built-in Audio” in the sound config GUI now) and how to configure the number of channels to use or allow the GUI to change the number.


pactl unload-module module-alsa-sink
pactl load-module module-alsa-sink device=hw:0,8 channels=8

makes it work with 8 channels instead of 2.

So the open question I was not able to answer myself as of yet:

How to get this closer to the “just works” status I find on other systems: Just connect HDMI and select the HDMI output in the audio config GUI.

Without using aplay -l to get a list of devices, speaker-test to find which of the many displayed is actually producing sound and finally using pactl load-module to be able to use that and pactl unload-module to get rid of that device in the GUI after the hdmi output has been disconnected again.

Suggesting you RTFM with no clue to documentation to help you understand reconfiguring ALSA is typical useless condescension from stackexchange
But suggesting use of .asoundrc configuration file is ignorant of how ALSA is configured in Arch-based distributions to use a software server as default

Loading a PulseAudio sink statically is a better option but it would require creating a custom user PulseAudio configuration ~/.config/pulse/default.pa

But that is more complicated than a GUI solution:

  • Install package pavucontrol-qt
  • Open configuration tab - pavucontrol --tab=5
  • Select Profile: Digital surround 7.1 (HDMI 2) Output
  • Click the Lock icon on the right to lock the card profile

AFAIK KDE audio controls do not have the Profile lock feature for PulseAudio
pavucontrol is developed by PulseAudio and is the “normal” GUI for other DEs

If the Profile lock works, changing device.description = "Built-in Audio" is not really needed except for user aesthetics, but it can be implemented with a custom user configuration created in ~/.config/pulse/default.pa
PulseAudio/Examples#Renaming Devices - ArchWiki

sorry, I’m unsure if I don’t understand your reply or if you didn’t understand my problem.

pulseaudio doesn’t seem to “see” my hdmi sound output device. Only when I run
pactl load-module module-alsa-sink device=hw:0,8 channels=8
I can use it in pulseaudio.

Neither the default KDE audio config GUI, nor pavucontrol-qt show me any hint that I’ve got an hdmi audio device connected, it only shows the internal speakers and that the head phone jack is disconnected.

If you can only see speakers and headphone outputs you are probably looking at the Playback tab
pavucontrol --tab=3 rather than the Configuration tab pavucontrol --tab=5
Playback is the default tab if no --tab option is included

ALSA data in post #1 shows one onboard audio device card 0 with 6 subdevices for analog and digital audio

PulseAudio is probably connected to device 0: ALC3266 Analog because the 0 in Subdevices: 0/1 indicates it is not available for other audio connections

Digital output device 8: HDMI 2 detects connection to Pioneer VSX-924 receiver
Subdevices: 1/1 indicates device is available for audio playback and not connected to PulseAudio

I suggest:

  • Reboot system so PulseAudio is in default state without additional sink module

  • Post more information about PulseAudio configuration

    pactl list cards; pacmd dump
1 Like

oooohhh, yes, sorry. I didn’t get what you where trying to tell me.

Taking a closer look at the option of that the single drop that is shown below the header “Built-in Audio” which a locked lock-symbol besides it, and next to the label “Profile:” shows me over 30 profiles to chose from, and one of those is titled “Digital Surround 7.1. (HDMI 3) Output + Analog Stereo Input”.

Choosing that gives me the same result as the quite complex procedure I’ve described a few posts above. So that indeed is a much nicer solution, though one still does need to remember to use pavucontrol instead of the KDE inbuilt audio device management GUI.

If the Profile lock in pavucontrol is working as expected it should be persistent and user should not need to use pavucontrol every time system is booted

If the card is not locked to the desired profile, PulseAudio might need some reconfiguration to prevent profile being switched. But I can’t consider if any reconfiguration is needed without further information

1 Like