You are not logged in.

#1 2012-04-21 20:22:12

Foxandxss
Member
Registered: 2008-11-23
Posts: 16

[SOLVED] Alsa is trolling me! (It's changing card orders)

Hello, I have 3 dispositives capables of sound.

GPU's HDMI
My sound card
Monitor's webcam

In that order.

So I wrote a .asoundrc file:

defaults.pcm.card 1
defaults.pcm.device 0
defaults.ctl.card 1

So far so good, but it seems that every 2-3 reboots (or something like that) the order changes.

So, maybe I reboot and I find that my card is now the number 0, so I have to change that values. Maybe 2-3 reboots after, the card is the number 1 again.

Any idea?

Last edited by Foxandxss (2012-04-22 19:11:21)

Offline

#2 2012-04-21 20:30:30

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [SOLVED] Alsa is trolling me! (It's changing card orders)

You can assign their names in .asoundrc: use aplay -l to list them.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2012-04-21 20:39:52

Foxandxss
Member
Registered: 2008-11-23
Posts: 16

Re: [SOLVED] Alsa is trolling me! (It's changing card orders)

So if p.e:

card 1: XFi [Creative X-Fi], device 0: ctxfi [Front/WaveIn]

Should I put something like...

defaults.pcm.card XFi [Creative X-Fi]
defaults.pcm.device ctxfi [Front/WaveIn]
defaults.ctl.card XFi [Creative X-Fi]

Something like that? Just the text inside []?

Thanks!

Offline

#4 2012-04-21 20:42:02

Gcool
Member
Registered: 2011-08-16
Posts: 1,456

Re: [SOLVED] Alsa is trolling me! (It's changing card orders)

This section of the ALSA wiki page explains how to do it exactly.


Burninate!

Offline

#5 2012-04-21 22:14:37

6ng4n
Member
Registered: 2012-02-07
Posts: 84

Re: [SOLVED] Alsa is trolling me! (It's changing card orders)

I think this is easiest way

Create a file in /etc/modprobe.d called sound.conf and put these

options snd_your_default_card index=0
options snd_your_second_card index=1
options snd_etc.. index=2

I have cmi8768 ,onboard hda and usb audio

options snd_cmipci index=0
options snd_hda_intel index=1
options snd_usb-audio index=2

Last edited by 6ng4n (2012-04-21 22:17:40)

Offline

#6 2012-04-22 19:11:04

Foxandxss
Member
Registered: 2008-11-23
Posts: 16

Re: [SOLVED] Alsa is trolling me! (It's changing card orders)

6ng4n wrote:

I think this is easiest way

Create a file in /etc/modprobe.d called sound.conf and put these

options snd_your_default_card index=0
options snd_your_second_card index=1
options snd_etc.. index=2

I have cmi8768 ,onboard hda and usb audio

options snd_cmipci index=0
options snd_hda_intel index=1
options snd_usb-audio index=2

Indeed.

Thanks.

Offline

Board footer

Powered by FluxBB