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

Re: usb audio device & sound card



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mark Grieveson wrote:
> Mark Grieveson wrote:
>>> Hi.  I have a cheap usb audio device for Skype, and a regular
>>> sound card for the rest of the computer.  I'm using Etch.  I
>>> would like to be able to get sound when browsing the internet, or
>>> listening to music, or watching movies, from the soundcard, while
>>> simultaneously being able to use the usb audio device for Skype.
>>> 
> 
>> I created a file in my home directory named .asoundrc with the
>> following contents:
> 
>> pcm.!default { type hw card 1 }
> 
>> ctl.!default { type hw card 1 }
> 
> Thanks again for this suggestion.  I did have a brief glimmer of hope
> when messing around.
> 
> I tried this and it didn't seem to work.  I changed the file (ie,
> making one of the entries read "card 0" instead of "card 1", and it
> still didn't work (restarting after each change.)  I proceeded to
> mess around, without success.  Then, I deleted the file, restarted,
> and IT WORKED perfect.  The sound card provided sound for all the
> applications, while the usb-audio-device (the phone) worked with
> Skype.  I then retested it by restarting the computer once again,
> and, alas, it went back to normal, that being the usb-audio-device
> (the phone) providing sound for everything, and the sound card
> providing sound for nothing.
> 
> The fact that I can't get sound working properly for this computer
> and its devices has my Windows friends laughing at me (sound,
> apparently, is a "basic", and if Linux can't even handle that, well,
> "what good is it?").  So, to help me regain a bit of dignity, please
> share any knowledge you may have with me.
> 
> Thanks, Mark
> 
> 

Greetings Mark:

As others have said, it sounds like the cards are not always getting
recognized in the same order, so sometimes your sound card is card 0 and
sometimes it is card 1.  That used to happen to me once in a while, but
it hasn't lately.

In any event, you can verify that this is in fact what is happening by
looking at the contents of your /proc/asound/cards file.  It will list
all of the cards that the kernel recognizes.  The card statement in your
.asound file is telling the system which of those two cards (0 or 1) to
use as the default.

Another poster suggested modifications to the udev rules.  That is
certainly worth a try, but I'm not sure that udev is the process
responsible for ordering those cards.  I could certainly be wrong about
that, but a quick look through the rules didn't show me anything that
looked promising.

Back when my system was changing the order of my cards, I planned to
write a script and run it from my .bashrc file.  I was going to have the
script look at the contents of the /proc/asound/cards file and
dynamically generate my .asoundrc file based on the order of the cards
listed in /proc/asound/cards.  I never got around to it, and my system
hasn't changed the order of initialization in months, so I never got
around to doing it.  It would not be a difficult script to write, but if
it's not your thing, post the contents of your /proc/asound/cards file
and I'll post you back a script.

- -Scott

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFF6CkVS7FYdPX6+iYRAqQ3AJ9vPKkqHTYWiOhhddwVLcowCiuQxgCglelY
kLZ81G5vqqdxw8TeyU76g+s=
=Mk+M
-----END PGP SIGNATURE-----



Reply to: