⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 linux-sound.html

📁 Linus guide, Linus guide, Linus guide,
💻 HTML
📖 第 1 页 / 共 2 页
字号:
copy the kernel to the appropriate place, which is<TT>/boot/vmlinuz</TT> if you're using Red Hat. Do this by typing in<B><TT>cp arch/i386/boot/zImage /boot/vmlinuz</TT></B>, assumingyou're using Red Hat of course. (The kernel is /vmlinuz onSlackware. I don't know about other distributions.) If you use LILO toget into Linux, type <B><TT>lilo</TT></B>. If you use LOADLIN (loadingDOS/Win95 first and then using it to boot a copy of your kernel), youneed to copy the kernel (arch/i386/boot/zImage) to your DOSpartition. Again, there's more information on this available <AHREF="linux-kernel.html">right here</A>.</P><A NAME="diditwork"></A><H3><A NAME="11">Did it Work?</A></H3><P>Now, whatever you do to reload Linux totally, do it. In my case Iwould reboot. When your system spits out all its boot messages, here'swhat it should say about the soundcard:</P><PRE>Sound initialization started&lt;Sound Blaster 16 (4.13)&gt; at 0x220 irq 5 dma 1,7&lt;Sound Blaster 16&gt; at 0x330 irq 5 dma 0&lt;Yamaha OPL3 FM&gt; at 0x388Sound initialization complete</PRE><P>Of course, it will look different if you have a different type ofcard.  As long as you hear a little pop from the speakers orsomething, that means it was configured correctly.</P><A NAME="pnp"></A><H4><A NAME="12">PnP Cards and the Problems Associated with Them</A></H4><P>My soundcard is PnP and it cost me a lot of frustration andexperimentation. That's what you have to frequently do when usingLinux.  But on to the information you actually care about: how to fixit if it goes wrong for you.</P><P>If you think you followed the instructions on this page but getsomething similar to the following error message when you boot up,then it could be due to the PnP configuration. Here it is:</P><PRE>Sound initialization startedSound initialization complete</PRE><P>Along with error messages like that, you won't hear a pop made bythe speakers, either. You probably configured everything right (youknow, the IRQ, DMA, and I/O base address stuff), but the card is PnPand Linux doesn't like that (well, the stable kernel anyway). That'swhy you should set up your machine for PnP in the BIOS, if youcan. Another method is with the isapnptools utility, which I haven'tfigured out yet.  Information on it is available at <AHREF="http://www.roestock.demon.co.uk/isapnptools"TARGET="_top">http://www.roestock.demon.co.uk/isapnptools</A>.</P><P>Basically all that I had to do in the BIOS to get the soundcard towork was to change a setting in the PnP configuration. I have an AwardBIOS, and the option was &quot;PnP OS Installed&quot; and the answerwas &quot;Yes&quot;. All I had to do was change it to&quot;No&quot;. The reason this worked, I'm guessing, is that the BIOSset up the PnP devices for me because it was told that there was noPnP-aware operating system installed. Before, it was on&quot;Yes&quot; so it just left the configuration of all the PnPdevices (the soundcard included) up to Windows 95.</P><P>The above method should suit most people just fine. However, I alsohave an Ethernet card, and when I change those options in the BIOS, myEthernet card (a jumperless one) refuses to communicate with the restof the network. So, I have to load Windows 95 first, exit to DOS, andthen boot Linux using LOADLIN and my kernel. The command line forLoadlin is <B>loadlin kernel_file</B>. Make sure that the kernel fileyou're using is one with support for sound. The kernel file I'mreferring to is the actual kernel, which goes by the name of<B>vmlinuz</B> somewhere on your Linux filesystem (/boot/vmlinuz or/vmlinuz).</P><P>I leave the &quot;PnP OS Installed&quot; option to &quot;Yes&quot;when I want to boot into Windows 95 and then use Loadlin to loadLinux. Windows sets up the soundcard and gets it working, and theEthernet card works too. I exit from Windows by going to Start ->Shutdown and then choosing the option of &quot;Restart in MS-DOSmode&quot;, which is just quitting Windows and going to DOS.</P><P>If I make the &quot;PnP OS Installed&quot; option to &quot;No&quot;and then try the Windows -> Linux loading method, my soundcard willstill work, but my jumperless Ethernet card will not. So, I leave thatoption to &quot;Yes&quot; in the BIOS.</P><A NAME="players"></A><H3><A NAME="13">Sound Playing Programs</A></H3><P>Most of the major Linux distributions (Red Hat, Slackware, Debian,and Caldera) come with utilities to play sound. I don't know about theless well-known distributions, but they probably include themalso.</P><P>For <TT>.au</TT> formats, you don't even need to have a programinstalled for playing sound. All you have to have is the <B>cat</B>program and sound properly configured. At the prompt, you can type in<B><TT>cat soundfile.au &gt; /dev/audio</TT></B>. That should work for.au formats only.</P><A NAME="midi"></A><H4><A NAME="14">MIDI</A></H4><P>Personally, I use the program <B><TT>playmidi</TT></B>, which wasalready pre-installed on my Red Hat machine. If you didn't installthat package for Red Hat, it's <B><TT>playmidi-*.rpm</TT></B> fromyour local Red Hat mirror or your Red Hat CD-ROM. I'm using a wildcardbecause I'm too lazy to find out what the current version is... plus,I won't have to update this document if a new version of playmidicomes out. :-)</P><P>Playmidi is also available from SunSITE. As I'm writing this, it'savailable from <AHREF="http://sunsite.unc.edu/pub/Linux/apps/sound/players/"TARGET="_top">sunsite.unc.edu/pub/Linux/apps/sound/players/</A>.  Thebasic syntax is <B><TT>playmidi filename.mid</TT></B>.</P><A NAME="mp3"></A><H4><A NAME="15">MP3</A></H4><P>There are several good MP3 players that I'm aware of now. The onesthat I use often are <A HREF="http://www.xmms.org/">XMMS</A> (formerlyX11AMP) and <AHREF="http://www-ti.informatik.uni-tuebingen.de/~hippm/mpg123.html">mpg123</A>.There's also <AHREF="http://www.geocities.com/SiliconValley/Haven/5235/">GQMpeg</A>,which is a front-end to <B>mpg123</B>.</P><P>XMMS looks very similar to Winamp. You can even use Winamp skinsfor it. It supports playlists as well. As usual though, watch out forhigh system load that will cause your MP3 playing to skip.</P><A NAME="realaudio"></A><H4><A NAME="16">RealAudio</A></H4><P>You can download RealPlayer from <AHREF="http://www.real.com/">RealNetworks</A>. You can configureNetscape to use that as a plugin. The README included in the Linuxversion might have information on how to do that. If not, <AHREF="mailto:jgo@local.net">let me know</A> that itdoesn't.</P><A NAME="wav"></A><H4><A NAME="17">WAV</A></H4><P><A HREF="mailto:slinkp@angelfire.com">Paul Winkle</A> let me knowabout the <B>play</B> command. I checked, and it came with my Red Hat5.1 distribution. It uses <B>sox</B>, which can also convert betweenaudio formats and even do basic effects.</P><A NAME="comments"></A><H3><A NAME="18">Comments</A></H3><P><A HREF="mailto:PianoMan@virginia.edu">Dave Click</A> wrote in tosay that OPL3 is his soundcard... that kinda makes sense to me now, soif you've got the soundcard that he does, then you probably want toenable support for that also. Anyway, here's his message.</P><PRE>Just like to say I really like your page... i'm just getting started withlinux and this is helping me out a lot. I have something to add,surprisingly... in section #9 - setting up sound, you mention:Generic OPL2/OPL3 FM synthesizer supportOPL3 is my sound card - it's a Yamaha, and in Win95 that's my setting forhow it plays Midi.I don't know if that helps... i don't know what opl stands for oranything...</PRE><P><A HREF="mailto:sstuvel@wins.uva.nl">Sybren Stuvel</A> wrote:</P><PRE>I really like to contribute to your pool of Linux-info!Here's my addendum:I own a Creative Labs Soundblaster 16. These are the settings:PORT: 220  IRQ:5  DMA:1,5Now for the problem: make menuconfig has a default IRQ 7. As youcan see, mine is 5. The menu refuses to change the IRQ to 5!!! Mysolution: stick with the 7 for now. As you have configured the wholething, close the menu, and edit the .config-file manually. This way youcan set the IRQ to 5, and everything goes as planned!</PRE><P>Just leaving like that didn't work for me, but I have a strangesystem that has a lot of stuff that doesn't work without some extraconfiguration. He also wrote that doing a <B><TT>cat/dev/sndstat</TT></B> will show all the information about yoursoundcard.</P><A NAME="mutant"></A><H4><A NAME="19">Mutant Soundcards</A></H4><P>If you have a weird mutant soundcard from some obscure company,take a look at <A HREF="submissions/AaronKuhn-OPL3">this text file</A>written by <A HREF="mailto:akuhn@usa.net">Aaron Kuhn</A>. It was toolong to include here and convert to nice HTML so I thought I'd leaveit in its unmodified glory. :-)</P><HR><P>Questions, comments, suggestions? This is currently in adevelopment stage of Beta, which means it's not guaranteed to work yetbut I'm pretty sure it will work. If it works for you, please let meknow. My e-mail address is <AHREF="mailto:jgo@local.net">jgo@local.net</A>.</P><HR><P><B><FONT SIZE="-1">Copyright &copy; 1997-1999 <AHREF="mailto:jgo@local.net">Joshua Go(jgo@local.net)</A>. All rights reserved. Permission to use,distribute, and copy this document is hereby granted. You may modifythis document as long as credit to me is given.</FONT></B></P></BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -