8

I'm looking for a way to configure HDMI audio output via the command line using pulseaudio. I was able to get it running by using pavucontrol and changing it in the configuration tab, but I need a way to automate the process. I haven't been able to find any documentation at all so far. The system is a lucid install.

Edit: From what I've found, I can use pacmd set-card-profile to do this. However, whenever I try, I get an error like the following (using the default profiles as defined in /usr/share/pulseaudio/alsa-mixer/profile-sets/default.conf)

# pacmd set-card-profile 0 hdmi-stereo
Welcome to PulseAudio! Use "help" for usage information.
>>> Failed to set card profile to 'hdmi-stereo'.

# pacmd set-card-profile 0 analog-stereo
Welcome to PulseAudio! Use "help" for usage information.
>>> Failed to set card profile to 'analog-stereo'.

Why can't I change these from command line when pavucontrol works to change them?

Daenyth
  • 768

3 Answers3

15

I was using the tool wrong. The correct way to do it was pactl set-card-profile 0 output:hdmi-audio. You can get a list of avilable profile names by running pacmd list-cards.

Daenyth
  • 768
0

Open a terminal and type:

sudo apt-get install alsamixergui

Then run it (Alt+F2 or press super key):

alsamixergui

A window will open for sound cofiguration...

decent
  • 88
-1

I found a simpler way to do this - on the Hardware tab of the System Settings Sound control, right-click on the profile drop down and select Digital Stereo (HDMI) Output + Analog Stereo input from the list.