LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-05-2007, 09:46 AM   #1
bookie
Member
 
Registered: Nov 2006
Location: Sweden
Distribution: Testing just about everything.....Debian still a favourite and now Dreamlinux!!
Posts: 320

Rep: Reputation: 30
Unhappy Alsa Problems


Hi again, I have had problems installing my sound card on slackware 11. I tried to use alsaconf, but that didn't work so well. I have two sound cards on my computer - one is inbuilt in the motherboard and the other I have added. The strange thing is - alsaconf finds both of them, but only the inbuilt one comes up when I run alsamixer? I will add that I choose the sound card that I have added myself. Why does alsaconf choose the wrong one? The inbuilt one is a intel and the other diamond multimedia sonic impact. Even though the sonic impact card is old - it is better than the built in one.
Has anyone any ideas as what I can do to make alsa choose the right card.

bookie
 
Old 05-05-2007, 10:05 AM   #2
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
Rebuild

The easiest way that I've found to keep alsa from using the wrong soundcard is to either modprobe -r unwantedmodule or just recompile your kernel and don't even enable the module for said unwanted soundcard.
 
Old 05-05-2007, 10:15 AM   #3
bookie
Member
 
Registered: Nov 2006
Location: Sweden
Distribution: Testing just about everything.....Debian still a favourite and now Dreamlinux!!
Posts: 320

Original Poster
Rep: Reputation: 30
Re Alsa problems

Thanks for the quick response manwichmakesameal. Do you think that you could elaborate a little for a newbie. Don't know all the commands and how to go about them, so a little more info would be greatly appreciated.
 
Old 05-05-2007, 10:27 AM   #4
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
commands

modprobe -r will just remove the unwanted module, (driver for soundcard or whatever). So if you do lsmod, you get something like
Code:
x_tables               11460  5 xt_tcpudp,iptable_nat,ipt_LOG,xt_state,ip_tables
it87                   16656  0
hwmon_vid               2688  1 it87
i2c_isa                 3456  1 it87
eeprom                  5456  0
tuner                  59496  0
bttv                  167604  0
video_buf              19780  1 bttv
ir_common              29636  1 bttv
compat_ioctl32          1024  1 bttv
i2c_algo_bit            6728  1 bttv
btcx_risc               3848  1 bttv
nvidia               4703828  20
tveeprom               13264  1 bttv
snd_emu10k1           126720  2
snd_rawmidi            19104  1 snd_emu10k1
firmware_class          7104  2 bttv,snd_emu10k1
snd_ac97_codec         93024  1 snd_emu10k1
ac97_bus                1728  1 snd_ac97_codec
snd_pcm                69000  4 snd_pcm_oss,snd_emu10k1,snd_ac97_codec
snd_seq_device          6284  4 snd_seq_oss,snd_seq,snd_emu10k1,snd_rawmidi
snd_page_alloc          7304  2 snd_emu10k1,snd_pcm
snd_util_mem            3328  1 snd_emu10k1
rtc_cmos                6804  0
joydev                  7808  0
videodev               25600  1 bttv
rtc_core                6740  1 rtc_cmos
rtc_lib                 2944  1 rtc_core
On my system, the snd_emu10k1 is the module for my soundcard. If I didn't want it loaded, I would just do modprobe -r snd_emu10k1. When you unload a module, you have to make sure it's not being used by anything though. So you may want to log out of X then use modprobe.
 
Old 05-05-2007, 10:52 AM   #5
bookie
Member
 
Registered: Nov 2006
Location: Sweden
Distribution: Testing just about everything.....Debian still a favourite and now Dreamlinux!!
Posts: 320

Original Poster
Rep: Reputation: 30
Re Alsa problems

Thanks for all the info, but I am still at a loss as to what I should write in the command console. Sorry to seem a bit dense. Some things with linux take a little longer for me to grasp. Getting on a bit now.

bookie
 
Old 05-05-2007, 11:08 AM   #6
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
console

When you run modprobe, you have to be root. So your prompt might look like:
Code:
root@graceland:~#
So when you type in commands, it will look like:
Code:
root@graceland:~# modprobe -r snd_emu10k1
To get to root, just type su, then it will prompt you for the root password. Type it in and hit enter. Only log in as root WHEN ABSOLUTELY NECESSARY. Like they say, "Don't take the name of root in vain." You can run lsmod as normal user, so you don't need to be root. So to see a list of loaded modules, just do:
Code:
allen@graceland:~$lsmod

Last edited by manwichmakesameal; 05-05-2007 at 11:10 AM.
 
Old 05-05-2007, 11:10 AM   #7
netcrawl
Member
 
Registered: Jan 2004
Location: British Columbia
Distribution: Slackware64-current, aarch64
Posts: 220

Rep: Reputation: 141Reputation: 141
I find the simplest way to disable onboard sound is to disable the option in BIOS settings; this assumes the option is available in your MB's BIOS settings, and that you do not want to use onboard sound at all.
 
Old 05-06-2007, 12:20 PM   #8
bookie
Member
 
Registered: Nov 2006
Location: Sweden
Distribution: Testing just about everything.....Debian still a favourite and now Dreamlinux!!
Posts: 320

Original Poster
Rep: Reputation: 30
Success

Thanks a lot guys. I hadn't even given it a thought to change the info in bios. I tried netcrawl's way because it was easiest - and that I don't run the risk of removing something that I might need in the future.
Once again, thanks

bookie
 
Old 07-10-2007, 07:07 PM   #9
AlfredSka
LQ Newbie
 
Registered: Mar 2003
Posts: 22

Rep: Reputation: 0
Another Fix

Another solution to the problem:

If you want to keep both sound cards running (for whatever reason), you can specify which card gets which ID at load time.
Code:
cat /proc/asound/modules
Copy that information down EXACTLY.
Code:
cd /etc/modprobe.d
Look for a file named "sound", "alsa", or "alsa-base"
Edit the file you have, for example:
Code:
su
nano /etc/modprobe.d/sound
Add lines:
Code:
install sound-slot-0 NAME_CARD_1
install sound-slot-1 NAME_CARD_2
For example on my system I have:
install sound-slot-0 snd_emu10k1
install sound-slot-1 snd_bt87x
install sound-slot-2 snd_usb_audio

I have commented out the alias lines that were originally in the file as well, and it hasn't caused problems yet, but if you do run into problems, just make sure the name of the alias is correct. (Pay particular attention to dashes being used when underscores should be used)

ctrl-O saves the file
ctrl-x exits from nano

Reboot the system and see if it works.

IF IT DOESN'T WORK there's another ugly solution:
create ".asoundrc" in home directory with the following:

Code:
pcm.!default {
        type hw
        card 2
        }

ctl.!default {
        type hw
        card 2
        }
Change "card #" to whichever number represents the sound card you want to use.

You can find the card # by: "alsamixer -c#" until you hit the one you're looking for.

For reference, the first solution was mostly ripped from https://bugs.launchpad.net/ubuntu/+s...ver/+bug/56482
while the second solution was taken from the ALSA Wiki

Last edited by AlfredSka; 07-10-2007 at 07:15 PM.
 
Old 07-11-2007, 01:01 PM   #10
bookie
Member
 
Registered: Nov 2006
Location: Sweden
Distribution: Testing just about everything.....Debian still a favourite and now Dreamlinux!!
Posts: 320

Original Poster
Rep: Reputation: 30
Hi AlfredSka

Thanks for the update. I appreciate the help.

bookie
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems with ALSA choylee2000 Debian 0 01-09-2005 10:09 AM
ALSA problems 2.6.5 nashirak Debian 5 06-24-2004 01:38 PM
alsa problems... socket9001 Slackware 1 04-27-2004 12:32 AM
alsa problems Channi Slackware 3 03-24-2004 08:31 AM
Problems with OSS while trying to avoid problems in ALSA (scratchy sound) GT_Onizuka Linux - General 1 02-05-2004 11:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:59 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration