Next Previous Contents

2. The integrated sound board

2.1 ALSA versus the AC'97 Driver

I have used both solutions successfully. However I noticed while working on a speech synthesis system (I was involved in a small accessibility project), that the kernel driver does not seem to be able to re-sample, whereas Alsa does it perfectly.

2.2 Alsa

Getting the ALSA drivers

So we will be compiling the latest sources from ALSA, which should work for all other distributions as well... only the kernel sources will change because mandrake uses specific patches.

You may get your kernel sources from your distribution or from http://www.kernel.org

Here can be found Mandrake sources for the kernel used in 8.0:

ftp://ftp.univ-savoie.fr/pub/Linux/Mandrake/8.0/i586/Mandrake/RPMS/kernel -source-2.4.3-20mdk.i586.rpm

(link seems to be broken, I wish I had made a copy if someone needed but here is the problem with that distribution, mirrors are not kept long enough)

and grab the tarball from ALSA:

ftp://ftp.alsa-project.org/pub/driver/alsa-driver-0.9.0beta10.tar.bz2

Installation

Install your kernel sources, in my case:

rpm -ivh kernel-source-2.4.3-20mdk.i586.rpm

Then decompress alsa drivers:

bzip2 -d alsa-driver-0.9.0beta10.tar.bz2 && tar -xvf alsa-driver-0.9.0beta10.tar

Make them and install them and create the devices files:

cd alsa-driver-0.9.0beta10 && make install && ./snddevices

Edit /etc/modules.conf to set everything, and add to it the following lines:

alias char-major-116 snd
alias char-major-14 soundcore
alias sound-slot-0 snd-card-0
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
alias snd-card-0 snd-card-intel8x0
warning: Christian Cardinale rf.libertysurf@elanidrac.naitsirhc reports that he had to change 'snd-card-intel8x0' for 'snd-intel8x0', which corresponds to what I have for my Debian system, I no longer remember, but I think this one is the mandrake name, if it doesn't work, just use to the other, ok?

2.3 Alsa the Debian way

I've switched to Debian some time after writing this howto and wanted to give some instructions about it: Things may change a little depending on which version you're using, I use Debian sarge, currently the testing version.

Using a Debian package with a precompiled kernel

First of all, you can directly download the appropriate precompiled alsa modules: find out which kernel you're using

uname -r

2.4.20-3-k7 (should be 2.4.18-k7 or something like that for a woody/stable)

apt-get install alsa-modules-2.4.20-3-k7

the card is the "intel8x0 (PCI: Intel i810/i820/i830/i840/MX440 integrated audio)"

you should also install the recommended package alsa-utils

apt-get install alsa-utils

now, check the file /etc/alsa/modutils/0.9 against the one given further on this howto. It may also be necessary to run update-modules as root to ensure that these lines get into /etc/modules.conf, although the package installation probably does it itself.

Using a Debian kernel source package

I was forced to recompile my kernel when I got an usb adsl modem. (make-kpkg binary --initrd is something you want to look at someday, but it's off topic)

I'm assuming, you've done at least the following steps:

install the alsa sources and two useful packages: apt-get install alsa-source alsa-utils alsa-base debconf will ask you the following questions:

Say Yes if you want to build ALSA driver with ISA PnP version.
If your computer doesn't support ISA PnP, you may say No. 
Build ALSA driver with ISA PnP?

You can safely select 'no'

Say Yes if you want to build ALSA driver with debugging code.
Build ALSA driver with debugging code?

We don't need that either, so select 'no'

You can choose cards to be built by selecting cards you want.
Each selection is a same name to a option of configure script '--with-cards'.
The following list are short descriptions of the options to show what they mean.
Select cards to be built.

Select card intel8x0 (PCI: Intel i810/i820/i830/i840/MX440 integrated audio) and exit.

cd /usr/src

tar xzvf alsa-driver.tar.gz

cd modules/alsa-driver

./configure

make && make install

now, check the file /etc/alsa/modutils/0.9 against this following one.

/etc/alsa/modutils/0.9

I only remember changing the cards_limit from 4 to 1, to prevent warnings, any modification of it should be followed by running update-modules in order to regenerate /etc/modules.conf

### DEBCONF MAGIC
# This file was automatically generated by alsa-base's debconf stuff

alias char-major-116 snd
alias char-major-14 soundcore
alias snd-card-0 snd-intel8x0
alias sound-slot-0 snd-card-0 
options snd major=116 cards_limit=1 device_mode=0660 device_gid=29 device_uid=0

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

2.4 Kernel Approach: The AC'97 Driver

If you are using a 2.4 or later kernel you can use the Audio Codec '97 (AC'97) sound driver, as the integrated sound card is AC'97 complaint.

You may enable your soundcard with a kernel module, as a matter of fact, you should be able to just use the module without even recompiling your kernel, because most GNU/Linux distributions have it already, just type:

modprobe i810_audio

and you should see something like this in your syslog:

  Intel 810 + AC97 Audio, version 0.21, 21:31:04 Apr 15 2002
  i810: SiS 7012 found at IO 0xd800 and 0xdc00, IRQ 11
  i810_audio: Audio Controller supports 2 channels.
  ac97_codec: AC97 Audio codec, id: 0x414c:0x4710 (ALC200/200P)
  i810_audio: AC'97 codec 0 supports AMAP, total channels = 2

or type

dmesg | less and scroll to see the kernel messages.

If everything went fine, you may add i810_audio to /etc/modules so it will autoload everytime you boot:

echo "i810_audio" >> /etc/modules

or you like monolitic kernels (no modules), follow the step above to install the kernel sources and say Y to Sound card support and Y to Intel ICH (i8xx) audio support compile your kernel, install, reboot and now your integrated soundcard is working.

If you don't know how to compile a kernel, read the Kernel HOWTO, it's easy and you'll get a optimized kernel for you system, also you'll learn a bit about that talk of using the source code (yes you are already taking advantage of it :-)


Next Previous Contents