Switch two sound cards without restarting In Debian

Source: Internet
Author: User

In a small space with severe electromagnetic interference, the built-in sound card of the notebook is generally poor, at least my n600c background noise is very obvious. For better results or digital output, you can only use an external sound card, including the PCMCIA Interface and USB interface. The former is expensive, for example, audigy2 Zs notebook; the latter, such as my Linglong II, is cost-effective.

In Linux, it is not as easy as windows to choose which sound card to use in the control panel as the preferred device. After a period of research, I found a method that is acceptable, at least you do not need to restart the system. First
Save the following text as/etc/modutils/sound_cards, and then sudo
Update-modules. This command will process all the files in/etc/modutils and synthesize the/etc/modules. conf file.

Alias snd-card-0 snd-Maestro
Alias snd-card-1 snd-USB-Audio
Options snd-Maestro Index = 0
Options snd-USB-audio Index = 1
Options snd-USB-audio enable = "1"

To switch to a USB sound card:

Sudo/etc/init. d/ALSA force-unload
Sudo modprobe snd-USB-Audio

Similarly, to switch to the built-in sound card (using the maestro3 chip:

/Etc/init. d/ALSA force-unload
Modprobe snd-maestro3

Note that force-unload will automatically kill all processes that use sound cards, such as Firefox, volume control, and BMP. If no such process is running, you can directly unload it, or rmmod snd-maestro3 unload the module like this.

Another method is to applyProgramFor example, in "preference-> plug-in-> output", select the output plug-in as ALSA, and then select the desired audio device and audio mixing device in the configuration of ALSA. Other applications are similar. In fact, if you only care about one application, it is easier.

Finally, Gentoo users can refer to this tip and thank Acura for providing it.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.