Sound always changes back to HDMI from analog on reboot

Archived topics about LMDE 1 and LMDE 2
Locked
cookiem

Sound always changes back to HDMI from analog on reboot

Post by cookiem »

Hi everyone,

I'm running LMDE 2 Betsy Cinnamon on a Mac Mini (late 2012). Every time I restart, the sound output always changes back to HDMI from analog. I have to go to the GUI Menu > Preferences > Sound to change the selected "HDMI / Displayport" to "Analog Output".

When I list the sinks available, right after booting, using the command "pacmd list-sinks" at the command line, reports "1 sink(s) available" - "<alsa_output.pci-0000_00_1b.0.hdmi-stereo-extra2>". Only after I go into the GUI Menu > Preferences > Sound to manually select "Analog Output", then the command line "pacmd list sinks" reports "2 sink(s) available." - both the original "<alsa_output.pci-0000_00_1b.0.hdmi-stereo-extra2>" and also "<alsa_output.pci-0000_00_1b.0.analog-stereo>". So, a boot script like "pacmd set-default-sink 1" doesn't work, since sink 1 (analog-stereo) is not available until I select it in the GUI!

Does anyone know how I can make "Analog Output" stick as default on reboots?

Code: Select all

uname -a
returns:

Code: Select all

Linux 3.16.0-4-amd64 #1 SMP Debian 3.16.39-1 (2016-12-30) x86_64 GNU/Linux

Code: Select all

cat /proc/asound/modules
returns:

Code: Select all

 0 snd_hda_intel

Code: Select all

pacmd list-sinks
(after GUI selection of "Analog Output") reports:

Code: Select all

2 sink(s) available.
    index: 0
	name: <alsa_output.pci-0000_00_1b.0.hdmi-stereo-extra2>
	driver: <module-alsa-card.c>
	flags: HARDWARE DECIBEL_VOLUME LATENCY FLAT_VOLUME DYNAMIC_LATENCY
	state: SUSPENDED
	suspend cause: IDLE 
	priority: 9950
	volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB
	        balance 0.00
	base volume: 65536 / 100% / 0.00 dB
	volume steps: 65537
	muted: no
	current latency: 0.00 ms
	max request: 0 KiB
	max rewind: 0 KiB
	monitor source: 0
	sample spec: s16le 2ch 44100Hz
	channel map: front-left,front-right
	             Stereo
	used by: 0
	linked by: 0
	configured latency: 0.00 ms; range is 0.50 .. 371.52 ms
	card: 0 <alsa_card.pci-0000_00_1b.0>
	module: 6
	properties:
		alsa.resolution_bits = "16"
		device.api = "alsa"
		device.class = "sound"
		alsa.class = "generic"
		alsa.subclass = "generic-mix"
		alsa.name = "HDMI 2"
		alsa.id = "HDMI 2"
		alsa.subdevice = "0"
		alsa.subdevice_name = "subdevice #0"
		alsa.device = "8"
		alsa.card = "0"
		alsa.card_name = "HDA Intel PCH"
		alsa.long_card_name = "HDA Intel PCH at 0xa0710000 irq 49"
		alsa.driver_name = "snd_hda_intel"
		device.bus_path = "pci-0000:00:1b.0"
		sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card0"
		device.bus = "pci"
		device.vendor.id = "8086"
		device.vendor.name = "Intel Corporation"
		device.product.id = "1e20"
		device.product.name = "7 Series/C210 Series Chipset Family High Definition Audio Controller"
		device.form_factor = "internal"
		device.string = "hdmi:0,2"
		device.buffering.buffer_size = "65536"
		device.buffering.fragment_size = "32768"
		device.access_mode = "mmap+timer"
		device.profile.name = "hdmi-stereo-extra2"
		device.profile.description = "Digital Stereo (HDMI)"
		device.description = "Built-in Audio Digital Stereo (HDMI)"
		alsa.mixer_name = "Intel PantherPoint HDMI"
		alsa.components = "HDA:10134206,106b5800,00100302 HDA:80862806,80860101,00100000"
		module-udev-detect.discovered = "1"
		device.icon_name = "audio-card-pci"
	ports:
		hdmi-output-2: HDMI / DisplayPort 3 (priority 5700, latency offset 0 usec, available: yes)
			properties:
				device.icon_name = "video-display"
				device.product.name = "LCDTV"
	active port: <hdmi-output-2>
  * index: 1
	name: <alsa_output.pci-0000_00_1b.0.analog-stereo>
	driver: <module-alsa-card.c>
	flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY FLAT_VOLUME DYNAMIC_LATENCY
	state: IDLE
	suspend cause: 
	priority: 9959
	volume: front-left: 16869 /  26% / -35.36 dB,   front-right: 16869 /  26% / -35.36 dB
	        balance 0.00
	base volume: 65536 / 100% / 0.00 dB
	volume steps: 65537
	muted: no
	current latency: 231.01 ms
	max request: 64 KiB
	max rewind: 64 KiB
	monitor source: 2
	sample spec: s16le 2ch 44100Hz
	channel map: front-left,front-right
	             Stereo
	used by: 0
	linked by: 0
	configured latency: 371.52 ms; range is 0.50 .. 371.52 ms
	card: 0 <alsa_card.pci-0000_00_1b.0>
	module: 6
	properties:
		alsa.resolution_bits = "16"
		device.api = "alsa"
		device.class = "sound"
		alsa.class = "generic"
		alsa.subclass = "generic-mix"
		alsa.name = "CS4206 Analog"
		alsa.id = "CS4206 Analog"
		alsa.subdevice = "0"
		alsa.subdevice_name = "subdevice #0"
		alsa.device = "0"
		alsa.card = "0"
		alsa.card_name = "HDA Intel PCH"
		alsa.long_card_name = "HDA Intel PCH at 0xa0710000 irq 49"
		alsa.driver_name = "snd_hda_intel"
		device.bus_path = "pci-0000:00:1b.0"
		sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card0"
		device.bus = "pci"
		device.vendor.id = "8086"
		device.vendor.name = "Intel Corporation"
		device.product.id = "1e20"
		device.product.name = "7 Series/C210 Series Chipset Family High Definition Audio Controller"
		device.form_factor = "internal"
		device.string = "front:0"
		device.buffering.buffer_size = "65536"
		device.buffering.fragment_size = "32768"
		device.access_mode = "mmap+timer"
		device.profile.name = "analog-stereo"
		device.profile.description = "Analog Stereo"
		device.description = "Built-in Audio Analog Stereo"
		alsa.mixer_name = "Intel PantherPoint HDMI"
		alsa.components = "HDA:10134206,106b5800,00100302 HDA:80862806,80860101,00100000"
		module-udev-detect.discovered = "1"
		device.icon_name = "audio-card-pci"
	ports:
		analog-output: Analog Output (priority 9900, latency offset 0 usec, available: unknown)
			properties:
				
		analog-output-speaker: Speakers (priority 10000, latency offset 0 usec, available: no)
			properties:
				device.icon_name = "audio-speakers"
		analog-output-headphones: Headphones (priority 9000, latency offset 0 usec, available: yes)
			properties:
				device.icon_name = "audio-headphones"
	active port: <analog-output>
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Karakoram

Re: Sound always changes back to HDMI from analog on reboot

Post by Karakoram »

We are many in this situation.

If somebody know the correct answer. This answer will be spread around the globe...

Serious.
Penn

Re: Sound always changes back to HDMI from analog on reboot

Post by Penn »

This happened to me on 17.2.

Install "pavucontrol". Open it. It should be in the sound and video seciton of the menu but if it isn't for some reason just type pavucontrol in the terminal. On the far right is a tab for configuration. Turn off HDMI and leave analog on.
cookiem

Re: Sound always changes back to HDMI from analog on reboot

Post by cookiem »

Penn wrote:This happened to me on 17.2.

Install "pavucontrol". Open it. It should be in the sound and video seciton of the menu but if it isn't for some reason just type pavucontrol in the terminal. On the far right is a tab for configuration. Turn off HDMI and leave analog on.
Thanks for the suggestion ... but this didn't work for me. There is no option to turn HDMI off in the Configuration tab. I think it's because there is only one sound controller on the Mac Mini which controls both HDMI and analog audio, and as a result there's only one option ("Built-In Audio") in the Configuration tab (even though "Built-In Audio" has multiple profiles (including HDMI & Analog)).

I tried setting HDMI as fallback in the "Output Devices" tab, but that didn't fix the issue either.
Karakoram

Re: Sound always changes back to HDMI from analog on reboot

Post by Karakoram »

Same thing for me. The solution doesn't work.
Bill Statler

Re: Sound always changes back to HDMI from analog on reboot

Post by Bill Statler »

Same problem here, and I found a working solution (probably somewhere on this forum, but I don't remember). This is on LMDE 2 MATE (might be slightly different on Cinnamon):

Menu > Preferences > Startup Applications > Add
Name: Sound Prefs = analog stereo [or whatever you like]
Command: pactl set-card-profile 0 output:analog-stereo+input:analog-stereo
Comment: Use 'pactl' to set sound hardware
Save

Next time you restart, this command will execute and change your output and input to analog-stereo.

One thing that might be different on your system is the card profile number. It's 0 on my system. As I recall, I found this using pactl list. This command spews out a ton of info, but way down at the bottom ought to be a section that looks something like this:

Code: Select all

Card #0
	Name: alsa_card.pci-0000_00_1b.0
	Driver: module-alsa-card.c
	Owner Module: 6
	Properties: ...
If your sound card is something other than #0, substitute the correct number in the pactl set-card-profile... command.
Bill Statler

Re: Sound always changes back to HDMI from analog on reboot

Post by Bill Statler »

Here's where I found the above info:
Setting the Default Audio in Linux Mint
Locked

Return to “LMDE Archive”