OK - feel a bit stupid now! Finally cracked this one, but to be honest, I think it only because I am a little more confortable with Linux these days!
Here is the solution for all you newbies out there. My examples are for Fedora Core 1 using my build in sound card Via 8233 (or RealTek card as it is shown in Windows) however these instructions should work for pretty much anyone as long as you know what sound card you have installed:
I strongly suggest that you install the alsa drivers using rpm rather than installing by compiling them. If you have a package manager like apt / synaptic, life is a breeze when time comes for you to update your system. Just my two cents, but it can save a lot of time, especially for a newbie.
1. First find out what kernel you are running by running uname -a at a command prompt. Here is an example from my system:
[root@localhost ademalet]# uname -a
Linux localhost.localdomain 2.4.22-1.2129.nptl #1 Mon Dec 1 08:46:47 EST 2003 i686 athlon i386 GNU/Linux
You can see from the above that I am running kernel 2.4.22-1.2129.ntpl
This piece of information is important as you need to make sure that you download all the components required that match your kernel version. If you don't get the right one, it won't work. If you upgrade your kernel you will also need to upgrade your corresponding alsa components.
2. Download the alsa components required to get things to work. My favourite site is
http://freshrpms.net
Just follow the links for your distribution and get the following files (making sure you understood what I wrote in step 1 about matching the files for your kernel version!):
alsa-driver
kernel-module-alsa
alsa-lib
alsa-lib-devel
alsa-utils
alsamixer
It might be also a good idea if you get the following file if you use xmms so that you can utilise your new alsa driver as opposed to using compatibility mode. Also it will help you test that you got alsa working. The file to get is:
xmms-alsa-1.2.8-3.2.fr
(This assumes that you are using xmms 1.2.8-3.2. If not, just get the version for the version of xmms you are using on your system)
3. Get a terminal window up so you can get a command prompt up.
4. Ensure that you are in super user mode
e.g.
[ademalet@localhost ademalet]$ su -
Password:
[root@localhost root]#
3. Go to the directory where you downloaded everything and then install both "alsa-driver" and "kernel-module-alsa" packages. e.g.
[root@localhost root]# cd /tmp
[root@localhost root]# rpm -ivh alsa-driver-version_number_here.rpm
Your system will now install the driver (you will see a series of ### as it installs
next
[root@localhost root]# rpm -ivh kernel-module-version_number_here.rpm
4. Install "alsa-lib" package and then "alsa-lib-devel" in the same manner as shown above. e.g.
[root@localhost root]# rpm -ivh alsa-lib-version_number_here.rpm
[root@localhost root]# rpm -ivh alsa-lib-devel-version_number_here.rpm
5. Install Install "alsa-utils" package and then "alsamixer" as shown above. e.g.
[root@localhost root]# rpm -ivh alsa-utils-version_number_here.rpm
[root@localhost root]# rpm -ivh alsamixer-version_number_here.rpm
6. Edit your modules.conf file:
[root@localhost root]# kedit /etc/modules.conf
My original modules.conf looked like this:
alias eth0 b44
alias usb-controller usb-uhci
alias usb-controller1 ehci-hcd
alias ieee1394-controller ohci1394
alias sound-slot-0 via82cxxx_audio
post-install sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -L >/dev/null 2>&1 || :
pre-remove sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -S >/dev/null 2>&1 || :
My NEW modules.conf now looks like this:
alias eth0 b44
alias usb-controller usb-uhci
alias usb-controller1 ehci-hcd
alias ieee1394-controller ohci1394
#alias sound-slot-0 via82cxxx_audio
#post-install sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -L >/dev/null 2>&1 || :
#pre-remove sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -S >/dev/null 2>&1 || :
# ALSA portion
alias char-major-116 snd
alias snd-card-0 snd-via82xx
# module options should go here
# OSS/Free portion
alias char-major-14 soundcore
alias sound-slot-0 snd-card-0
post-install sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -L >/dev/null 2>&1 || :
pre-remove sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -S >/dev/null 2>&1 || :
# card #1
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss
If you have another card to mine, I suggest you look at the following web site to get an idea of what to put:
http://www.alsa-project.org/alsa-doc/
7. Now you have to remove your old sound modules. To do this, make sure that you kill ALL sound enabled programs such as xmms, arts, even applications like gaim etc - Basically kill all currently running programs as well as any applets that maybe running in your "systray".
Using my system as an example, do the following:
[root@localhost root]# /sbin/modprobe -r via82cxxx_audio
The system should just return you to a prompt indicating everything worked. If you can an error here, please double-check that you have closed ALL audio enabled programs
If necessary issue a 'ps -A' at the prompt and look through all processes running and if you see anything running that looks like it might be sound related, issue a 'kill -9 naughty_program' at prompt!
By the way, if you have another sound card, replace the via82cxxx_audio with whatever driver you were using (check your modules.conf file to get an idea of what your system was using before).
8. Time to load all the other necessary ALSA components like the compatibility drivers etc:
At your prompt issue this:
root@localhost root]# /sbin/modprobe snd-maestro3; /sbin/modprobe snd-pcm-oss; /sbin/modprobe snd-mixer-oss; /sbin/modprobe snd-seq-oss
You should be returned to the prompt after entering all of this!
8. Now run kmix (if you running KDE) or aumix - e.g.
root@localhost root]# kmix
A window should come up - just adjust all the appropriate sound levels. If you are using GNOME use aumix and adjust all the sound settings.
9. Everything should now work.
Testing to see if ALSA works:
I suggest you use xmms as most people have xmms installed.
1. Open xmms
2. Right click on the xmms window and select "Options"
3. From the next menu that comes up, select "preferences"
4. In the Audio I/O Plugins tab, you will see a section on Output plugin. Change this from aRts output to ALSA.
5. Close xmms
6. reopen xmms
7. Play a song and everything should work.
------------------
I hope this helped someone! Good luck and if you have any problems, please come to this forum.