English AWE32/AWE64 HOWTO. Written by Dennis Vink. AWE-32/64 & LINUX REDHAT ------------------------ 1.1 - Why i wrote this HOWTO 1.2 - Some information about AWE32 and the AWE64 2.1 - Kernelversion 2.2 - Installing the AWE32 via isapnptools 2.3 - Installing new kernal and configuring kernel 2.4 - SFX-Utils & Soundfonts 2.5 - Playmidi 1.4 3.1 - Final word 1.1 - Why is wrote this HOWTO ----------------------------- I started writing this HOWTO after many hours of work to get my AWE-32 PnP to work with Linux. The normal audio worked, ofcourse, because it's a SB compatible soundcard. After many hours trying with my old kernel 2.0.36, i decided to install a new kernel, 2.1.132, because it has AWE32/64 support build-in. With 2.0.36 there was a patch to patch the kernel, but as happens often, it didn't work. I could have accept audio only (MP3's, etc. :)) but i find it important that the system works com- pletely, and that includes the AWE 32 Synthesise (WaveTable). To make a long story short, i downloaded kernel 2.1.132 and configged it. After reading a textfile about the AWE-32 i learned i had to install the sounddrivers as a module. (because the soundcard is a isa pnp card, and with isapnp you have to load the drivers before any other driver for the soundcard is loaded but more about that later.) After i done that, and after i entered some stuff in /etc/rc.d/rc.local, i rebooted. Then the correct modules were loaded, but still no midi. It seemed that i had to install SFXLOAD. A utility that loads a soundfont into the memory of the AWE. So i dowloaded that one also, even the newest version. After com- piling, a make install, and download of a soundfont, i was waiting full with expectation for the result, but you guess it... nothing. SFXLOAD was whining about a library that didn't exist. Even after compilation as 'static' it continued displaying the same error message. Then i read what was updated in the new version of sfxutils, and i noticed the 'linked library' option was just added. A version before didn't contain the 'error'. (maybe there ain't no error, and i just don't get it :)) I downloaded, compiled, and installed an older version and i went to my /root/sound/mid directory. There i typed 'playmidi vlieger.mid' (a great Dutch number from Andre Hazes) but playmidi returned a error because it couldn't find a playback device. It seemed i had to install a new version of playmidi. So i went to the site of playmidi, and downloaded the newest version. After compilation and installation i went back to my midi direc- tory, and typed once again 'playmidi vlieger.mid' and then... THERE WAS MUSIC! And because it cost me so many hours i decided to write this HOWTO. Here i describe all steps i followed, and how i got it to work. This concludes the 'why' section. 1.2 - Some information about AWE32 and the AWE64 ------------------------------------------------ I'll keep this one really short :) Because Creative Labs(tm) doesn't want to write any drivers for Linux there is for the Linux users with a AWE little difference between an AWE-32 and an AWE-64. Because of this the installation is such a hassle. 2.1 - Kernelversion ------------------- I got my AWE32 to work with kernel 2.1.132. Ofcourse you're free to install another kernel, but in any case 2.1.132 works good with the AWE (and all my other drivers that worked ok in 2.0.36 worked good with 2.1.132) For this kernel you can look on : ftp://ftp.crc.ca/mirrors/by-site/ftp.redhat.com/redhat/ or look http://uk.linux.org under topic 'archive sites' 2.2 - Installing the AWE32 via isapnptools ------------------------------------------ I assume that you have an AWE-32 or AWE-64 PnP, because there are no other AWE cards that are not PnP.(well, i don't know them) My /etc/isapnp.conf looks like this : ----------------------------[ begin ]---------------------------------------------------- (READPORT 0x0203) (ISOLATE) (IDENTIFY *) # AUDIO (CONFIGURE CTL0042/149467 (LD 0 (INT 0 (IRQ 5 (MODE +E))) (DMA 0 (CHANNEL 1)) (DMA 1 (CHANNEL 5)) (IO 0 (BASE 0x0220)) (IO 1 (BASE 0x0330)) (IO 2 (BASE 0x0388)) (ACT Y) )) # WaveTable (CONFIGURE CTL0042/149467 (LD 3 (IO 0 (BASE 0x0620)) (IO 1 (BASE 0x0A20)) (IO 2 (BASE 0x0E20)) (ACT Y) )) (WAITFORKEY) ----------------------------[ end ]---------------------------------------------------- The gameport and ide are not configured, but that's not really nessecary. If you really want it, you got to type : npdump > /etc/isapnp.conf and edit that file. All devices are uncommented, so be carefull what you do. With the PnP cards 'WaveTable' is detected only (IO 0 (BASE 0x0620)) but there are 3 nessecary. With me they are : (IO 0 (BASE 0x0620)) (IO 1 (BASE 0x0A20)) (IO 2 (BASE 0x0E20)) The above values are usually correct, but it can be different. Check this! You don't have to add isapnptools to the 'boot-scripts' such as /etc/rc.d/rc.local because the kernel 2.1.132 automaticly loads it. If that doesn't happen, you can add to /etc/rc.d/rc.local : ----------------------------[ begin ]---------------------------------------------------- if [ -x /etc/rc.d/init.d/isapnp ] then /etc/rc.d/init.d/isapnp start fi ----------------------------[ end ]---------------------------------------------------- and make a new file : /etc/rc.d/isapnp with the contents : ----------------------------[ begin ]---------------------------------------------------- #! /bin/sh # /etc/rc.d/init.d/isapnp: configure Plug and Play boards test -x /sbin/isapnp || exit 0 /sbin/isapnp /etc/isapnp.conf exit 0 ----------------------------[ end ]---------------------------------------------------- but probably that isn't nessecary :) From now on, while booting, the AWE-32 (or 64) ISA card will be configured. Now begins the dull part... configuring and recompilation of the kernel. 2.3 - Installing new kernal and configuring kernel -------------------------------------------------- If you already have a good kernel that supports AWE, or you just don't want to install a new kernel, you can skip section A and B. A. Untarring the new kernel --------------------------- If you downloaded the kernel (i assume 2.1.132) you move it to /usr/src. Example : You have downloaded kernel 2.1.132 and stored it in /root/ You type : # cd /usr/src # mv /root/linux-2.1.132.tar.gz . If there is in /usr/src a directory named 'linux' or 'linux-2.x.x.xx' delete it. e.g. : rm -rf linux or rm -rf linux-2.0.34 Now to untar the new kernel... # tar -zvxf linux-2.1.132.tar.gz When finished a new directory appears named 'linux' Enter this directory and type : # make mrproper # make menuconfig Now a menu appears on your screen where you can configure several things, and we come to section B. B. Base-configuration of the kernel ----------------------------------- The kernel you're configuring is completely 'standard'. You have to make several adjustments. The most options have a help option. Don't turn on stuff you don't know what it is or does! If you think you're finished, you can go to section C. If you never compiled a kernel before, i advice you to read the Kernel-HOWTO in /usr/doc/HOWTO. Don't yet configure the sound (look at section C :)) C. Soundconfiguration of the kernel & installing the new kernel --------------------------------------------------------------- In the menu 'sound' you see 'Sound Card Support'. Switch it on my pressing spacebar. A empty box means not installed, 'M' is installed a Module and a * is compiled in kernel. A module will be loaded afterwards. Install the Sound Card Support as 'M'. When you done that you'll get lots of other options, but only a few are important. Install '100% Sound Blaster compatibles (SB16/32/64, ESS, Jazz16) support' as 'M' module The following as module too :'Generic OPL2/OPL3 FM synthesizer support' and the 'FM synthesizer (YM3812/OPL-3) support'. Install the 'OSS sound modules' as 'M' (module). 'Additional low level sound drivers' on 'y' of '*'. and AWE32 synth as 'M' (module). Now press 'EXIT' until you get the possibility to save your changes. Save them and you'll return to the Linux prompt. Now we're going to cook the kernel :) (Another word for compiling) Type : # make dep # make clean # make zImage This takes a while... go make yourself a pizza... or two :) # make modules # make modules_install # cd /usr/src/linux/arch/i386/boot # cp zImage /boot # cd /boot Now we're going to give zImage a good name. (zImage is the compiled kernel) # mv zImage 2.1.132 Then we're going to ajust the lilo boot manager configuration file (because we want to boot the new kernel) # cd /etc # pico lilo.conf The contents of lilo.conf could be : boot=/dev/hda map=/boot/map install=/boot/boot.b prompt linear timeout=50 image=/boot/2.0.35 label=linux root=/dev/hda1 read-only To boot the new kernel (with the ability to boot the old kernel) you could change this into : boot=/dev/hda map=/boot/map install=/boot/boot.b prompt linear timeout=50 image=/boot/2.1.132 label=linux root=/dev/hda1 read-only image=/boot/2.0.35 label=2.0.35 root=/dev/hda1 read-only Edit lilo.conf and store it with CTRL-O. You end pico with CTRL-X. The values for your system could (and probably are) different! Make shure the settings are correct. Now type this : # lilo It'll show something like this : Added linux Added 2.0.35 [root@localhost etc]# This means you're ready for a reboot :) Reboot the computer and start linux. If everything went ok the system boots correctly. Look for possible errormessages. If something might go wrong while booting the kernel (kernel panic) reboot again and when prompted for boot: type 2.0.35 (or the label you gave your old kernel) If everything did go good, you can continue ;) Log in as root (or su to root) and go to the directory /etc/rc.d and edit the file rc.local Add to the file : # sound drivers modprobe sound insmod uart401 insmod sb io=0x220 irq=5 dma=1 dma16=5 mpu_io=0x330 insmod awe_wave sfxload /usr/synthgm.sbk The values of your soundblaster (io=0x220, etc.) can difer. Probably that's not the case, but it could be. Check it to make shure. Trust is good, Verifying is better. The last line is 'sfxload /usr/synthgm.sbk' SFXLoad is a program to add a soundfont to your soundcard. That brings us to 2.4 2.4 - SFX-Utils & Soundfonts ---------------------------- AweSFX is available on : http://bahamut.mm.t.u-tokyo.ac.jp/~iwai/awedrv/index.html You can try the newest version but it didn't work for me! I've downloaded the sources of version 0.4.2 (awesfx-0.4.2.tar.gz) I advice you to do the same. Unzip them just like you did with the kernel. Example, you've downloaded awesfx-0.4.2.tar.gz and stored it in /root/ Type : # tar -zvxf awesfx-0.4.2.tar.gz The directory awesfx-0.4.2 will be made, with in there the sources. # cd awesfx-0.4.2.tar.gz # xmkmf # make Makefiles # make all # make install # cp sfxload /bin Now you need a soundfont for your AWE. You can try on the following site : http://members.xoom.com/~yar/synthgm.sbk.gz but i doubt if that link is still valid. When i tried it didn't work. If it works for you, copy the file to /usr (cp synthgm.sbk.gz /usr) and type : # cd /usr # gunzip synthgm.sbk.gz If you can't download it from that site, you can always obtain it somewhere of the www, or if you have a windows machine with the AWE drivers installed, it's somewhere there ;) But you'll always find it. Now it's time to reboot... again. Boot linux and check for possible errormessages. If it's good they won't come and the sounddrivers plus soundfont will be loaded. 2.5 - Playmidi 1.4 ------------------ Linux RedHat 5.1 got playmidi version 1.3, but you have to update it in order to make use of your AWE-32 Wave-Table. You must download version 1.4 on : http://playmidi.openprojects.net It's simple to compile and to install. Untar it (tar -zvxf playmidi-2.4.tar.gz) and enter the directory that has been made. Then read the README or INSTALL and follow the instructions. If i'm correct you must enter the following : # ./configure # make # make install And then... THEN is your AWE installed. Find a midifile, or download it somewhere. Go to the directory where that midi file holds up. Lets say the midi file is named 'vlieger.mid' and located in the directory /root/sound/mid Then you type : # cd /root/sound/mid # playmidi vlieger.mid and enjoy :) If you don't here a bloody thing, check if everything is connected, volume is on (if in X, check the Mixer too), etc. 3.1 - Final Words ----------------- This concludes the AWE-32/64 HOWTO. This HOWTO is a good document made out of several HOWTO's combined with a little part of my knowledge about Linux. My English sucks, so don't bug me about it ;) After reading this HOWTO, and trying and trying and trying (etc.) you still don't get it to work, please mail me on mad@madmadness.demon.nl (even if you do get it to work i like to hear from you ;) You might also want to visit my Linux page -> http://members.tripod.com/~lunix and if you have a site/page, please link me ;) Greatings too : KaaSJoNGeN, DeaL, PHiLO, FrieK, Quu, and the rest :)