Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How to set the default sound card
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
naga jolokia
n00b
n00b


Joined: 28 Dec 2013
Posts: 10
Location: Berlin

PostPosted: Wed Mar 04, 2015 3:46 pm    Post subject: How to set the default sound card Reply with quote

Following Gentoo's alsa wiki an ~/.asoundrc
Code:
defaults.pcm.!card PCH
defaults.pcm.!device 0
helped mpg123 to use the right sound card. But alsamixer fails, it still tries HDMI. OK, I can change it by hand using F6, but not all programs have this option (f.e. flashplayer). So I tried to change the order of the cards.
Code:
# cat /proc/asound/cards
 0 [HDMI           ]: HDA-Intel - HDA Intel HDMI
                      HDA Intel HDMI at 0xf7c34000 irq 30
 1 [PCH            ]: HDA-Intel - HDA Intel PCH
                      HDA Intel PCH at 0xf7c30000 irq 31
according to the wiki in /etc/modprobe.d/alsa.conf one should set options snd cards_limit=2 and add 2 lines
Code:
options snd-hda-intel id=PCH index=0
options snd-hda-intel id=HDMI index=1
The comments in that file tell me to run 'update-modules' but as it seems no longer available I rebooted in the hope that the moduls will get their config during loading process. But the order in /proc/asound/cards is untouched. So my questions are: Is the file read when modules get loaded? Or is there another way to set the default sound card (prefered: system wide)?

P.S.: I also tried enabling the alias snd-card-[01] snd-hda-intel lines without success
Back to top
View user's profile Send private message
lagalopex
Guru
Guru


Joined: 16 Oct 2004
Posts: 562

PostPosted: Wed Mar 04, 2015 5:58 pm    Post subject: Reply with quote

With the "defaults.pcm" you only set the playback default. You also need to set the control ("defaults.ctl") to the other card.

OR

For the module options:
Code:
options snd-hda-intel id=PCH,HDMI index=0,1
Back to top
View user's profile Send private message
naga jolokia
n00b
n00b


Joined: 28 Dec 2013
Posts: 10
Location: Berlin

PostPosted: Thu Mar 05, 2015 10:55 am    Post subject: Reply with quote

lagalopex wrote:
With the "defaults.pcm" you only set the playback default. You also need to set the control ("defaults.ctl") to the other card.

OK, that works. Should be documented in the Wiki.
lagalopex wrote:

OR

For the module options:
Code:
options snd-hda-intel id=PCH,HDMI index=0,1

That does change the order in /proc/asound/cards, but alsamixer still defaults to HDMI.
Meanwhile I found an option in UEFI to disable HDMI audio completely. That did the job!
Seems there is a Patch
[url]https://groups.google.com/forum/#!topic/linux-sunxi/oGa0L2T0jiY[/url]
for ARM boards which accept kernel command line options hdmi.audio=EDID:0 to disable audio if not supported by the attached screen and without the EDID part to disable HDMI audio completely, but it doesn't seem to be included in X86_64. This options on my commandline were ignored.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum