I'm constantly switching between USB Wireless Headphones and Speakers, so I need my sound to work properly on both exits.
Wireless Headphones: Plantronics .Audio 995USB
Speakers: Sony (Some old Hi-Fi)
When I first installed Linux (I think it was Ubuntu 12.04 LTS) I didn't have any sound in my headphones so I wrote to a couple of forums and I ended up using the following solution:
Created a home/user/.asoundrc file that looks like this
- Code: Select all
pcm.card0 {
type hw
card 0
}
ctl.card0 {
type hw
card 0
}
pcm.!default front:Audio
Now this is extremely peculiar. In some weird way before I introduced the .asoundrc file both sound devices worked simultaneously. For example I have a + and - buttons on my headphones for vol up/down. Even though no movie, song, video clip etc would play sound through the headphones whenever I pressed the +/- buttons I could hear a very clear "pop" sound when the volume had reached maximum/minimum value. This is when I realized that the machine acknowledged both sound devices but had to be configured to be able to switch between one another.
Nevertheless, except for this popping sound I couldn't play any other sound through my headphones, before I introduced the .asoundrc file.
And this is where it goes absolutely chaotic...
Usually when I have my .asoundrc file only the Headphones would play, so even if I plug them out, the motherboard sound wouldn't play unless I renamed the .asoundrc file.
However on rare occasions the motherboard sound card plays even when .asoundrc is present, and to make it even worse sometimes it doesn't play when the .asoundrc file is NOT present.
A few months ago when I used mainly Windows 7 this would work smoothly. When the headphones were plugged in the USB they became the default sound device, when they were plugged out the motherboard sound became the defauld sound device. That's what I'm trying to accomplish on Mageia right now. I want effortless auto-switching between sound devices.
I have no idea where to start but using an .asoundrc file to manually manipulate sound devices (which doesn't even work properly) seems very barbaric to me.
Any ideas ? Thanks.