Re: Making an (external) soundcard optional

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On So, 2009-01-04 at 12:15 +0000, Dominique Michel wrote:> Le Sun, 04 Jan 2009 12:02:44 +0100,> Tobias Gödderz <goedderz@xxxxxxxxxxx> a écrit :
> > I have a laptop and use an Aureon 5.1 USB card from Terratec at home,> > and my internal sound card if I'm on the road. I am, of course, too lazy> > to switch the default soundcard manually, so I wonder if there is a way> > to either> > > > i)  make the USB soundcard the default, and automatically use the other> >     if the USB card isn't available> > or> > ii) use a multi device to dupe the audio stream to both cards that> >     doesn't fail if one card isn't available, but silently ignores that> >     and just plays on the other one.> > > > Of course I could write a script that changes my ~/.asoundrc if the USB> > card is available or not, if there is no sane way to do it with alsa.> > > > It must be also possible to use udev. I am no an expert, but I know that, if> udev load your usb sound card before alsasound, no matter what is> in /etc/modprobe.conf, the usb sound card will be the first one, that imply the> default card.> > Most users do not want that and blacklist usb_snd_audio> in /etc/modprobe,d/blacklist.
Hm. I tried using the index=n option, and it works in the way that theorder is preserved, but if card 0 isn't plugged in, even at boot time,alsa still tries to use it, which results in:
ALSA lib confmisc.c:768:(parse_card) cannot find card '0'ALSA lib conf.c:3513:(_snd_config_evaluate) functionsnd_func_card_driver returned error: No such file or directoryALSA lib confmisc.c:392:(snd_func_concat) error evaluating stringsALSA lib conf.c:3513:(_snd_config_evaluate) function snd_func_concatreturned error: No such file or directoryALSA lib confmisc.c:1251:(snd_func_refer) error evaluating nameALSA lib conf.c:3513:(_snd_config_evaluate) function snd_func_referreturned error: No such file or directoryALSA lib conf.c:3985:(snd_config_expand) Evaluate error: No such file ordirectoryALSA lib pcm.c:2184:(snd_pcm_open_noupdate) Unknown PCM default
-- open STDOUT, "|-"    and print "uJa tsonrehtP  lreahrekc"    or  print pack "nN"x4, unpack "vV"x4, <STDIN>


------------------------------------------------------------------------------_______________________________________________Alsa-user mailing listAlsa-user@xxxxxxxxxxxxxxxxxxxxxxxxxx://lists.sourceforge.net/lists/listinfo/alsa-user

[Index of Archives]     [ALSA Devel]     [Linux Audio Users]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]

  Powered by Linux