You are not logged in.

#1 2016-07-17 00:35:34

SquiddyBlob
Member
Registered: 2013-09-13
Posts: 24

[SOLVED] ATI HDMI audio doesn't work with pure ALSA

Issue: My R7 250 ATI/AMD graphics card's HDMI audio does not work with ALSA alone, but Pulseaudio works fine.

OK, so I decided to remove Pulseaudio as I feel like I don't need it. Well, it seems that I do need it for my sound to work correctly hmm
However, I would like to switch to a pure ALSA setup.

I also find it very strange that Pulseaudio, which sits on top of ALSA, seems to work, but not ALSA itself.

I tried setting

radeon.audio=1

in the kernel parameters, but that had no effect (so I removed it to avoid confusion).

The below commands were all run with pulseaudio uninstalled

$ lspci -nn | grep Audio
01:00.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Cape Verde/Pitcairn HDMI Audio [Radeon HD 7700/7800 Series] [1002:aab0]
$ lsmod | grep snd
snd_usb_audio         147456  0
snd_usbmidi_lib        28672  1 snd_usb_audio
snd_rawmidi            28672  1 snd_usbmidi_lib
snd_seq_device         16384  1 snd_rawmidi
snd_hda_codec_hdmi     45056  1
snd_hda_intel          32768  0
snd_hda_codec         106496  2 snd_hda_codec_hdmi,snd_hda_intel
snd_hda_core           61440  3 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel
snd_hwdep              16384  2 snd_usb_audio,snd_hda_codec
snd_pcm                86016  5 snd_usb_audio,snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_core
snd_timer              28672  1 snd_pcm
snd                    65536  10 snd_usb_audio,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_rawmidi,snd_usbmidi_lib,snd_hda_codec,snd_hda_intel,snd_seq_device
soundcore              16384  1 snd
usbcore               200704  14 uas,btusb,snd_usb_audio,uvcvideo,usb_storage,ohci_hcd,ohci_pci,snd_usbmidi_lib,ehci_hcd,ehci_pci,hid_roccat_common,usbhid,xhci_hcd,xhci_pci
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: HDMI [HDA ATI HDMI], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
$ cat /etc/modprobe.d/alsa-base.conf 
options snd_hda_intel index=0
$ dmesg | grep radeon
[    9.282009] [drm] radeon kernel modesetting enabled.
[    9.745237] fb: switching to radeondrmfb from VESA VGA
[    9.745780] radeon 0000:01:00.0: Invalid PCI ROM header signature: expecting 0xaa55, got 0xffff
[    9.746550] radeon 0000:01:00.0: VRAM: 2048M 0x0000000000000000 - 0x000000007FFFFFFF (2048M used)
[    9.746552] radeon 0000:01:00.0: GTT: 2048M 0x0000000080000000 - 0x00000000FFFFFFFF
[    9.746643] [drm] radeon: 2048M of VRAM memory ready
[    9.746644] [drm] radeon: 2048M of GTT memory ready.
[    9.936897] [drm] radeon: dpm initialized
[   10.051906] radeon 0000:01:00.0: WB enabled
[   10.051909] radeon 0000:01:00.0: fence driver on ring 0 use gpu addr 0x0000000080000c00 and cpu addr 0xffff88021ed31c00
[   10.051911] radeon 0000:01:00.0: fence driver on ring 1 use gpu addr 0x0000000080000c04 and cpu addr 0xffff88021ed31c04
[   10.051913] radeon 0000:01:00.0: fence driver on ring 2 use gpu addr 0x0000000080000c08 and cpu addr 0xffff88021ed31c08
[   10.051914] radeon 0000:01:00.0: fence driver on ring 3 use gpu addr 0x0000000080000c0c and cpu addr 0xffff88021ed31c0c
[   10.051916] radeon 0000:01:00.0: fence driver on ring 4 use gpu addr 0x0000000080000c10 and cpu addr 0xffff88021ed31c10
[   10.052687] radeon 0000:01:00.0: fence driver on ring 5 use gpu addr 0x0000000000075a18 and cpu addr 0xffffc90001035a18
[   10.153754] radeon 0000:01:00.0: VCE init error (-110).
[   10.153761] radeon 0000:01:00.0: radeon: MSI limited to 32-bit
[   10.153785] radeon 0000:01:00.0: radeon: using MSI.
[   10.153809] [drm] radeon: irq initialized.
[   11.223951] fbcon: radeondrmfb (fb0) is primary device
[   11.244587] radeon 0000:01:00.0: fb0: radeondrmfb frame buffer device
[   11.280654] [drm] Initialized radeon 2.43.0 20080528 for 0000:01:00.0 on minor 0
$ dmesg | grep snd
[    9.048137] snd_hda_intel 0000:01:00.1: Handle vga_switcheroo audio client
[    9.048141] snd_hda_intel 0000:01:00.1: Force to non-snoop mode
[   10.036614] usbcore: registered new interface driver snd-usb-audio
[   11.210659] snd_hda_codec_hdmi hdaudioC0D0: HDMI ATI/AMD: no speaker allocation for ELD

By far the most worrying message is the "no speaker allocation".

When running

alsamixer

I can only mute and unmute one channel (S/PDIF) and it remains at 00 volume (edit: what I mean by this is that I cannot increase the volume, and there is no bar above it). However, when I try to play something (via VLC) it says

[00000000009f2a98] alsa audio output error: cannot open ALSA device "default": No such file or directory

What is most interesting though is that Pulseaudio works fine hmm

Any help would be much appreciated!!!

Last edited by SquiddyBlob (2016-07-18 07:21:07)

Offline

#2 2016-07-17 10:19:25

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,866

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

Pulseaudio tends to change alsa configuration files to make PA and alsa work together.
Those changes often make it impossible for pure alsa to work.

look for ~/.asoundrc and /etc/asound.conf .
if they exist, move/delete them, reboot and try again.
( the reboot is to make sure alsa creates a fresh configuration using real hardware without any interference from pa created stuff.
there are other ways to achieve that, but rebooting is the simplest one. )


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#3 2016-07-17 11:27:52

SquiddyBlob
Member
Registered: 2013-09-13
Posts: 24

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

~/.asoundrc and /etc/asound.conf do not exist sad
I also backed up and then removed /var/lib/alsa/asound.state and generated a new one via reboot. Now they are different, but the symptoms seem identical.

Old:

state.SB {
	control.1 {
		iface MIXER
		name 'Channel Mode'
		value '2ch'
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 '2ch'
			item.1 '4ch'
			item.2 '6ch'
		}
	}
	control.2 {
		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
		}
	}
	control.3 {
		iface MIXER
		name 'Front Playback Switch'
		value.0 true
		value.1 true
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.4 {
		iface MIXER
		name 'Surround Playback Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 64'
			dbmin -6400
			dbmax 0
			dbvalue.0 -6400
			dbvalue.1 -6400
		}
	}
	control.5 {
		iface MIXER
		name 'Surround Playback Switch'
		value.0 false
		value.1 false
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.6 {
		iface MIXER
		name 'Center Playback Volume'
		value 0
		comment {
			access 'read write'
			type INTEGER
			count 1
			range '0 - 64'
			dbmin -6400
			dbmax 0
			dbvalue.0 -6400
		}
	}
	control.7 {
		iface MIXER
		name 'LFE Playback Volume'
		value 0
		comment {
			access 'read write'
			type INTEGER
			count 1
			range '0 - 64'
			dbmin -6400
			dbmax 0
			dbvalue.0 -6400
		}
	}
	control.8 {
		iface MIXER
		name 'Center Playback Switch'
		value false
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.9 {
		iface MIXER
		name 'LFE Playback Switch'
		value false
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.10 {
		iface MIXER
		name 'Headphone 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
		}
	}
	control.11 {
		iface MIXER
		name 'Headphone Playback Switch'
		value.0 true
		value.1 true
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.12 {
		iface MIXER
		name 'Loopback Mixing'
		value Enabled
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 Disabled
			item.1 Enabled
		}
	}
	control.13 {
		iface MIXER
		name 'Front Mic Playback Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 31'
			dbmin -3450
			dbmax 1200
			dbvalue.0 -3450
			dbvalue.1 -3450
		}
	}
	control.14 {
		iface MIXER
		name 'Front Mic Playback Switch'
		value.0 false
		value.1 false
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.15 {
		iface MIXER
		name 'Rear Mic Playback Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 31'
			dbmin -3450
			dbmax 1200
			dbvalue.0 -3450
			dbvalue.1 -3450
		}
	}
	control.16 {
		iface MIXER
		name 'Rear Mic Playback Switch'
		value.0 false
		value.1 false
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.17 {
		iface MIXER
		name 'Line Playback Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 31'
			dbmin -3450
			dbmax 1200
			dbvalue.0 -3450
			dbvalue.1 -3450
		}
	}
	control.18 {
		iface MIXER
		name 'Line Playback Switch'
		value.0 false
		value.1 false
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.19 {
		iface MIXER
		name 'Auto-Mute Mode'
		value Enabled
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 Disabled
			item.1 Enabled
		}
	}
	control.20 {
		iface MIXER
		name 'Input Source'
		value 'Front Mic'
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 'Front Mic'
			item.1 'Rear Mic'
			item.2 Line
		}
	}
	control.21 {
		iface MIXER
		name 'Input Source'
		index 1
		value 'Front Mic'
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 'Front Mic'
			item.1 'Rear Mic'
			item.2 Line
		}
	}
	control.22 {
		iface MIXER
		name 'Capture Volume'
		value.0 28
		value.1 28
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 46'
			dbmin -1600
			dbmax 3000
			dbvalue.0 1200
			dbvalue.1 1200
		}
	}
	control.23 {
		iface MIXER
		name 'Capture Switch'
		value.0 true
		value.1 true
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.24 {
		iface MIXER
		name 'Capture Volume'
		index 1
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 46'
			dbmin -1600
			dbmax 3000
			dbvalue.0 -1600
			dbvalue.1 -1600
		}
	}
	control.25 {
		iface MIXER
		name 'Capture Switch'
		index 1
		value.0 false
		value.1 false
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.26 {
		iface MIXER
		name 'Front Mic Boost Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 3'
			dbmin 0
			dbmax 3000
			dbvalue.0 0
			dbvalue.1 0
		}
	}
	control.27 {
		iface MIXER
		name 'Rear Mic Boost Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 3'
			dbmin 0
			dbmax 3000
			dbvalue.0 0
			dbvalue.1 0
		}
	}
	control.28 {
		iface MIXER
		name 'Line Boost Volume'
		value.0 0
		value.1 0
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 3'
			dbmin 0
			dbmax 3000
			dbvalue.0 0
			dbvalue.1 0
		}
	}
	control.29 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.30 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.31 {
		iface MIXER
		name 'IEC958 Playback Default'
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.32 {
		iface MIXER
		name 'IEC958 Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.33 {
		iface MIXER
		name 'IEC958 Default PCM Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.34 {
		iface MIXER
		name 'Master Playback Volume'
		value 44
		comment {
			access 'read write'
			type INTEGER
			count 1
			range '0 - 64'
			dbmin -6400
			dbmax 0
			dbvalue.0 -2000
		}
	}
	control.35 {
		iface MIXER
		name 'Master Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.36 {
		iface CARD
		name 'Front Mic Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.37 {
		iface CARD
		name 'Rear Mic Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.38 {
		iface CARD
		name 'Line Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.39 {
		iface CARD
		name 'Line Out Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.40 {
		iface CARD
		name 'Front Headphone Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.41 {
		iface CARD
		name 'SPDIF Phantom Jack'
		value true
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.42 {
		iface PCM
		name 'Playback Channel Map'
		value.0 0
		value.1 0
		comment {
			access read
			type INTEGER
			count 2
			range '0 - 36'
		}
	}
	control.43 {
		iface PCM
		name 'Capture Channel Map'
		value.0 0
		value.1 0
		comment {
			access read
			type INTEGER
			count 2
			range '0 - 36'
		}
	}
	control.44 {
		iface PCM
		device 1
		name 'Playback Channel Map'
		value.0 0
		value.1 0
		comment {
			access read
			type INTEGER
			count 2
			range '0 - 36'
		}
	}
	control.45 {
		iface PCM
		device 2
		name 'Capture Channel Map'
		value.0 0
		value.1 0
		comment {
			access read
			type INTEGER
			count 2
			range '0 - 36'
		}
	}
	control.46 {
		iface MIXER
		name 'PCM Playback Volume'
		value.0 255
		value.1 255
		comment {
			access 'read write user'
			type INTEGER
			count 2
			range '0 - 255'
			tlv '0000000100000008ffffec1400000014'
			dbmin -5100
			dbmax 0
			dbvalue.0 0
			dbvalue.1 0
		}
	}
	control.47 {
		iface MIXER
		name 'Digital Capture Volume'
		value.0 60
		value.1 60
		comment {
			access 'read write user'
			type INTEGER
			count 2
			range '0 - 120'
			tlv '0000000100000008fffff44800000032'
			dbmin -3000
			dbmax 3000
			dbvalue.0 0
			dbvalue.1 0
		}
	}
}
state.HDMI {
	control.1 {
		iface CARD
		name 'HDMI/DP,pcm=3 Jack'
		value true
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.2 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.3 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.4 {
		iface MIXER
		name 'IEC958 Playback Default'
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.5 {
		iface MIXER
		name 'IEC958 Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.6 {
		iface PCM
		device 3
		name ELD
		value '100005000010000100000000000000000000000009070700'
		comment {
			access 'read volatile'
			type BYTES
			count 24
		}
	}
	control.7 {
		iface PCM
		device 3
		name 'Playback Channel Map'
		value.0 0
		value.1 0
		value.2 0
		value.3 0
		value.4 0
		value.5 0
		value.6 0
		value.7 0
		comment {
			access 'read write'
			type INTEGER
			count 8
			range '0 - 36'
		}
	}
}
state.U0x46d0x805 {
	control.1 {
		iface PCM
		name 'Capture Channel Map'
		value 0
		comment {
			access read
			type INTEGER
			count 1
			range '0 - 36'
		}
	}
	control.2 {
		iface MIXER
		name 'Mic Capture Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.3 {
		iface MIXER
		name 'Mic Capture Volume'
		value 6144
		comment {
			access 'read write'
			type INTEGER
			count 1
			range '0 - 6144'
			dbmin 600
			dbmax 3000
			dbvalue.0 3000
		}
	}
}

New:

state.HDMI {
	control.1 {
		iface CARD
		name 'HDMI/DP,pcm=3 Jack'
		value true
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.2 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.3 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.4 {
		iface MIXER
		name 'IEC958 Playback Default'
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.5 {
		iface MIXER
		name 'IEC958 Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.6 {
		iface PCM
		device 3
		name ELD
		value '100005000010000100000000000000000000000009070700'
		comment {
			access 'read volatile'
			type BYTES
			count 24
		}
	}
	control.7 {
		iface PCM
		device 3
		name 'Playback Channel Map'
		value.0 0
		value.1 0
		value.2 0
		value.3 0
		value.4 0
		value.5 0
		value.6 0
		value.7 0
		comment {
			access 'read write'
			type INTEGER
			count 8
			range '0 - 36'
		}
	}
}
state.U0x46d0x805 {
	control.1 {
		iface PCM
		name 'Capture Channel Map'
		value 0
		comment {
			access read
			type INTEGER
			count 1
			range '0 - 36'
		}
	}
	control.2 {
		iface MIXER
		name 'Mic Capture Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.3 {
		iface MIXER
		name 'Mic Capture Volume'
		value 6144
		comment {
			access 'read write'
			type INTEGER
			count 1
			range '0 - 6144'
			dbmin 600
			dbmax 3000
			dbvalue.0 3000
		}
	}
}

Briefly looking at the output, the only difference is the state.SB, which I guess represented the internal sound (from the motherboard, not the graphics card which I'm trying to get working) which I disabled in the BIOS to prevent confusion.

Thanks for helping though.

Offline

#4 2016-07-17 11:40:38

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,410

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

ALSA's default "default" device points to hw:0,0 you have to make it point to hw:0,3 in your case: https://wiki.archlinux.org/index.php/Ad … ive_method

Since HDMI is a digital output you can only set ALSA to either output or not output sound, volume control is done by the receiver (your monitor in this case). To get adjustable software volume, you have to configure the softvol ALSA plugin: http://alsa.opensrc.org/How_to_use_soft … ter_volume

Pulseaudio implicitly takes care of all of this. Pure ALSA requires some configuration effort on your part.

@Lone_Wolf
Pulseaudio never adjusts any ALSA configuration (it can't for global files since it is started as your user and it doesn't create anything that would adjust ALSA configuration in  your $HOME dir) the only thing that does is the Arch provided convenience package pulseaudio-alsa which sets up a pulseaudio using ALSA sink to which ALSA-only applications can play to while using pulse's infrastructure)  and it only provides a /etc/asound.conf which can easily be replaced (and has a fallback that points back to hw:0,0 if pulse isn't started)

Offline

#5 2016-07-17 12:02:01

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,866

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

V1del wrote:

Pulseaudio never adjusts any ALSA configuration (it can't for global files since it is started as your user and it doesn't create anything that would adjust ALSA configuration in  your $HOME dir)

That may be valid since pulseaudio 7 was released in oktober 2015, but was not the case before that.
As a pure alsa user PA improvements don't matter much to me, but it's good to know they finally managed to make alsa userspace and pa userspace work together in a clean way.


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#6 2016-07-17 15:56:39

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,410

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

ALSA volumes will be affected, which shouldn't have a bearing on the problem we currently have at hand. You still shouldn't mix ALSA userspace and pulse userspace (unless it's a control pulse doesn't expose and hence doesn't change)

Offline

#7 2016-07-18 07:19:45

SquiddyBlob
Member
Registered: 2013-09-13
Posts: 24

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

V1del, you are awesome!!!
I guess I came in with too many assumptions about how ALSA worked due to using pulseaudio for so long.

I first setup the sound without softvol, but the sound was very loud (even when using my monitor to lower it) and there was a lot of crackling/static and sound skipping. However, when I switched to a softvol device, everything suddenly worked fine. This is very similar to the issue here: https://wiki.archlinux.org/index.php/Ad … r_clipping

My issue is solved, but, for education purposes, could you please tell me how I would lower the gain or whatever is necessary in the configuration to make the sound bearable wink Thanks so much regardless.

If anyone stumbles across this issue, here is my final /etc/asound.conf that at least works for me:

pcm.softvol {
    type softvol
    slave {
        pcm "hdmi"
    }
    control {
        name "Master"
        card 0
    }
}

pcm.!default {
    type plug
    slave.pcm "softvol"
}

ctl.!default {
    type hw
    card HDMI
}

Offline

#8 2016-07-18 08:10:42

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,410

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

Well you should now have a softvol provided volume meter that is adjustable in alsamixer I suppose. You can additionaly set hard limits on the volume range the softvol meter provides (see: http://www.alsa-project.org/alsa-doc/al … ns_softvol )

If that wasn't what you needed, you might have to ask someone else for further details, as I in fact, simply use pulseaudio for all of my audio needs and only have cursory knowledge of ALSA configuration in order to help with issues.

Offline

#9 2016-07-18 08:47:54

SquiddyBlob
Member
Registered: 2013-09-13
Posts: 24

Re: [SOLVED] ATI HDMI audio doesn't work with pure ALSA

Ah OK, I don't need anything else, everything is working fine for me (I can set the volume in alsamixer etc. but I was just wondering so that I could have more knowledge), thanks smile

Offline

Board footer

Powered by FluxBB