Ŀ¼ 14 Éù¿¨ 14.1 ¸ÅÒª 14.2 Ñ°ÕÒÕýÈ·µÄÉ豸 14.3 ÖØбàÒëÄÚºË 14.4 ´´½¨ºÍ²âÊÔÉ豸װÔصĽڵã 14.5 ³£¼ûµÄÎÊÌâ 14.6 MP3 ÒôÀÖ ============================================================= µÚ14 ÕÂÉù¿¨ ============================================================= (·ÒëÖгöÏÖµÄÈκÎÎÊÌâ»ò´íÎó£¬Çë¹ã´ó¶ÁÕß¼°Ê±·´À¡¸øÎÒ£ºfreebsdhandbook@163.com) 14.1 ¸ÅÒª FreeBSD Ö§³ÖºÜ¶àÖÖÉù¿¨£¬ÔÊÐíÄãÊä³ö¸÷ÖÖ¸ñʽµÄÒôÀÖ¡£°üÀ¨MP3,WAV,Ogg Vorbis µÈ µÈ¸ñʽµÄÒôÀÖ¡£FreeBSD Ports ÖÐÒ²°üº¬Á˺ܶàÓ¦ÓóÌÐò¿ÉÒÔÔÊÐíÄã±à¼ÒôÀÖÎļþ¡£ ¶ÁÍêÕâÕ£¬Ä㽫Á˽⵽ÕâЩ£º . ÈçºÎ¶¨Î»ÄãµÄÉù¿¨¡£ . ÈçºÎÅäÖÃÄãµÄϵͳÒÔ±ãÄãµÄÉù¿¨ÄÜ´ïµ½×î¼Ñ״̬¡£ . ͨ¹ýʹÓÃרÃŵijÌÐò²âÊÔÄãµÄÉù¿¨µÄ¹¤×÷״̬µÄ·½·¨¡£ . ÈçºÎ½â¾öÉù¿¨°²×°µÄһЩÎÊÌâ¡£ ¶ÁÕâÕÂ֮ǰ£¬ÄãÓ¦µ±Á˽âÕâЩ£º . ÈçºÎÅäÖúͰ²×°Ò»¸öÐÂÄںˣ¨µÚ9 Õ£© 14.2 Ñ°ÕÒÕýÈ·µÄÉ豸 ÔÚ¿ªÊ¼ÒÔÇ°£¬Ó¦¸ÃÒªÖªµÀÄãÓµÓеÄÉù¿¨µÄÐͺţ¬ËüËùÓõÄоƬ£¬»¹ÓÐËüÊÇPCI »¹ÊÇISA ¿¨¡£FreeBSD ¹ã·ºµØÖ§³Ö¶àÖÖPCI ¼°ISA ¿¨¡£Èç¹ûÔÚÏÂÃæÁбíÖÐûÓз¢ÏÖÓëÄãÒ»ÑùµÄ¿¨£¬Çë ²Î¿¼pcm Áª»úÊֲᡣÕâ²»ÊÇÍêÕûµÄÁÐ±í£»²»¹ýÒѾÁгöÁ˴󲿷ÖͨÓõÄÉù¿¨¡£ . Crystal 4237, 4236, 4232, 4231 . Yamaha OPL-SAx . OPTi931 . Ensoniq AudioPCI 1370/1371 . ESS Solo-1/1E . NeoMagic 256AV/ZX . Sound Blaster Pro, 16, 32, AWE64, AWE128, Live µÚ1 Ò³FreeBSD ʹÓÃÊÖ²á . Creative ViBRA16 . Advanced Asound 100, 110, and Logic ALS120 . ES 1868, 1869, 1879, 1888 . Gravis UltraSound . Aureal Vortex 1 or 2 ÄÚºËÖÐʹÓõÄÇý¶¯³ÌÐòÊÓËùÓµÓеÄÉù¿¨¶ø¶¨¡£ÏÂÃæµÄ¶ÎÂäÌṩÁ˸ü¶àµÄÐÅÏ¢ÒÔ¼°ÄÇЩÐè Òª¼ÓÈëÄÚºËÉèÖõÄ×ÊÁÏ¡£ 14.2.1 Creative, Advance ºÍESS Sound Cards Èç¹ûÓÐÉÏÃæÕâЩ¿¨Ö®Ò»£¬ÇëÔÚÄÚºËÖмÓÈë device pcm Èç¹ûÓÐPnP ISA ¿¨£¬Ò²ÇëÔÚÄÚºËÖмÓÈë device sbc ¶ÔÓÚ·ÇPnP ISA ¿¨£¬ÇëÔÚÄÚºËÖмÓÈë device pcm ºÍdevice sbc0 at isa? port0x220 irq 5 drq 1 flags 0x15 ÄÇЩÊÇĬÈϵÄÉèÖ᣿ÉÄÜÐèÒª¸Ä±äIRQ »òÆäËü¡£ÆäËüÐÅÏ¢Çë²Î¿¼sbc Áª»úÊֲᡣ ×¢Òâ: δ¾ÐÞ²¹µÄFreeBSD 4.0 ²»Ö§³ÖSound Blaster Live£»Õâ²»°üº¬ÔÚÕâ·ÝÎļþÖС£ ½¨ÒéÔÚ³¢ÊÔʹÓÃÕâÕÅ¿¨ÒÔÇ°¸üе½×îаæµÄ-STABLE¡£ 14.2.2 Gravis UltraSound Cards ¶ÔÓÚPnP ISA ¿¨£¬ÇëÔÚÄÚºËÖмÓÈë device pcm ºÍ device gusc Èç¹ûÓзÇPnP ISA ¿¨£¬ÇëÔÚÄÚºËÖмÓÈë device pcm ºÍ device gus0 at isa? port 0x220 irq 5 drq 1 flags 0x13 ¿ÉÄÜÐèÒª¸ü¸ÄIRQ »òÆäËü¡£ÆäËüÐÅÏ¢Çë²Î¿¼gusc Áª»úÊֲᡣ µÚ2 Ò³FreeBSD ʹÓÃÊÖ²á 14.2.3 Crystal Éù¿¨ ¶ÔÓÚCrystal ¿¨£¬ÇëÔÚÄÚºËÖмÓÈë device pcm ºÍ device csa 14.2.4 Ò»°ãÖ§³Ö ¶ÔÓÚPnP ISA »òPCI ¿¨£¬ÇëÔÚÄÚºËÉèÖÃÖмÓÈë device pcm Èç¹ûÓв»º¬bridge Çý¶¯³ÌÐòµÄ·ÇPnP ISA Éù¿¨£¬ÇëÔÚÄÚºËÖмÓÈë device pcm0 at isa? irq 10 drq 1 flags 0x0 ¿ÉÄÜÐèÒª¸Ä±äIRQ »òÆäËü£¬ÒÔ·ûºÏÓ²¼þÉèÖᣠ14.3 ÖØбàÒëÄÚºË ÔÚ¼ÓÈëËùÐèµÄÇý¶¯³ÌÐòÖÁÄÚºËÉèÖúó£¬ÇëÖØбàÒëÄںˡ£ÆäËüÐÅÏ¢Çë²Î¿¼ÊÖ²áµÄµÚ9.3 ½Ú¡£ 14.4 ½¨Á¢ºÍ²âÊÔÉ豸װÔصĽڵã ÖØÐÂÆô¶¯ºó£¬µÇ½²¢Ö´ÐÐcat /dev/sndstat¡£»á³öÏÖÀàËÆÏÂÃæµÄÊä³öÐÅÏ¢£º FreeBSD Audio Driver (newpcm) Sep 21 2000 18:29:53 Installed devices: pcm0: at memory 0xfeb40000 irq 5 (4p/1r +channels duplex) Èç¹û¿´µ½´íÎóÐÅÏ¢£¬±íʾǰÃæij¸ö²½Öè´íÁË¡£Èç¹û·¢ÉúÁË£¬ÇëÖØмì²éÒ»´ÎÄÚºËÉèÖÃÒÔ È·¶¨Ñ¡ÔñÁËÕýÈ·µÄÉ豸¡£ Èç¹ûûÓдíÎóÐÅÏ¢¶øÇÒÏÔʾpcm0£¬ÇëÖ´ÐÐsu ±ä³Éroot ²¢ÈçÏÂÖ´ÐУº # cd /dev # sh MAKEDEV snd0 Èç¹ûûÓдíÎóÐÅÏ¢¶øÇÒÏÔʾpcm1£¬Ê¹ÓÃsu ±ä³Éroot ²¢ÈçÏÂÖ´ÐУº # cd /dev # sh MAKEDEV snd1 Çë×¢ÒâÉÏÃæÈÎÒ»¸öÃüÁ²»»á²úÉú/dev/snd É豸£¡¶øÊDzúÉúÒ»×éÉ豸½Úµã°üÀ¨£º µÚ3 Ò³FreeBSD ʹÓÃÊÖ²á ˵Ã÷É豸 ÓëSPARC ¼æÈݵÄÉùÒôÉ豸/dev/audio Êý×ÖÉùÒôÉ豸/dev/dsp Ïó/dev/dsp£¬µ«Ã¿´ÎÈ¡ÑùΪ16 bits /dev/dspW /dev/midi midi ·ÃÎÊÉ豸 ¿ØÖƶ˿ڻìÒôÉ豸/dev/mixer /dev/music Level 2 ÒôÐò½Ó¿Ú /dev/sequencer ÒôÐòÉ豸 ¿É±à³ÌÉ豸½Ó¿Ú/dev/pss Èç¹û˳Àû£¬ÏÖÔÚÓ¦¸ÃÓиö¿ÉÕý³£¹¤×÷µÄÉù¿¨ÁË¡£Èç¹ûûÓУ¬Çë²Î¿¼ÏÂÒ»½Ú¡£ 14.5 ³£¼ûµÄÎÊÌâ 14.5.1. ÎÒÓöµ½Ò»¸öunsupported subdevice XX error£¡ Ò»¸ö»ò¶à¸öÉ豸½ÚµãûÓб»ÕýÈ·µÄ²úÉú¡£ÇëÖظ´ÉÏÃæµÄ²½Öè¡£ 14.5.2. ÎÒÓöµ½Ò»¸ösb_dspwr(XX) timed out µÄ´íÎó£¡ I/O port ûÓÐÉèÖÃÕýÈ·¡£ 14.5.3. ÎÒÓöµ½a bad irq XX µÄ´íÎó£¡ IRQ ÉèÖÃÓÐÎó¡£ÇëÈ·¶¨ÉèÖõÄIRQ ºÍÉù¿¨IRQ Ò»Ö¡£ 14.5.4.ÎÒÓöµ½¡°xxx: gus pcm not attached, out of memory¡± µÄ´íÎó¡£ÕâÊÇʲôÔì³É µÄ£¿ Èç¹û·¢ÉúÁË£¬±íʾûÓÐ×ã¹»µÄÄÚ´æÀ´Ê¹ÓÃÕâ¸öÉ豸¡£ 14.6 MP3 ÒôÀÖ 14.6.1 MP3 ²¥·ÅÆ÷ ×îÁ÷ÐеÄXFree86 MP3 ²¥·ÅÆ÷ÊÇXMMS¡£Winamp µÄskins Ò²Äܱ»ÓÃÔÚXMMS ÉÏ¡£XMMS Ò² Ö§³Ö²å¼þ¡£ XMMS ÄÜ´Óaudio/xmms port »òpackage Öа²×°¡£XMMS ½Ó¿ÚÊǺÜÖ±¹ÛµÄ£¬ËüÓÐÒ»¸ö²¥·Å Ŀ¼£¬Ò»¸öͼÐεľùºâÆ÷µÈ¡£ÕâЩ¶¼ºÜÏówinamp¡£Ò²¿ÉÒÔÔÚaudio/mpg123 port ÖÐÑ¡ÔñÒ» ¸öÃüÁîÐеÄMP3 ²¥·ÅÆ÷¡£¿ÉÒÔÕâÑù×ö£º µÚ4 Ò³FreeBSD ʹÓÃÊÖ²á # mpg123 -a /dev/dsp1.0 Foobar-GreatestHits.mp3 High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2 and 3. Version 0.59r (1999/Jun/15). Written and copyrights by Michael Hipp. Uses code from various people. See 'README' for more! THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK! Playing MPEG stream from BT - Foobar-GreastHits.mp3 ... MPEG 1.0 layer III, 128 kbit/s, 44100 Hz joint-stereo ÔÚÄãµÄϵͳÖУ¬/dev/dsp1.0 Ó¦¸Ã±»dsp É豸½Ó¿ÚËùÌæ»»¡£ 14.6.2 ת»»CD Òô¹ì ÔÚ°ÑCD »òCD Òô¹ìת»»³ÉMP3 ʱ£¬ÔÚCD ÉϵÄÉùÒôÊý¾Ý±ØÐ뱻תµ½Ó²ÅÌÉÏ¡£Õâ¿ÉÒÔ°ÑCDDA Êý¾Ýת³ÉWAV ÎļþÀ´Íê³É¡£cdda2wav ¹¤¾ß£¬ÊÇsysutils/cdrtools Ì×¼þµÄÒ»²¿·Ö¡£ÏÂÃæµÄ ÃüÁî¿ÉÒÔ°ÑÕû¸öCD ת³ÉÒ»¸ö¸ö£¨Ã¿¸öÒô¹ì£©WAV Îļþ£º # cdda2wav -D 0,1,0 -B -D 0,1,0Ö¸³öÁËSCSI É豸ÊÇ0,1,0£¬ËüÊÇÓëcdrecord -scanbus Êä³öÏà·ûºÏµÄ¡£×ª»» ÿ¸öÒô¹ì£¬¿ÉÒÔ¼ÓÉÏ-t Ñ¡Ï # cdda2wav -D 0,1,0 -t 7 Õâ¸öÀý×Ó¿ÉÒÔ´ÓCD ÉÏץȡ7 ¸öÒô¹ì¡£¿ÉÒÔÖ¸¶¨Ò»¸ö·¶Î§£¬Èç1 µ½7£º # cdda2wav -D 0,1,0 -t 1+7 cdda2wav Ö»Ö§³ÖSCSI CDROM Çý¶¯Æ÷¡£¶ÔÓÚIDE Çý¶¯Æ÷¿ÉÒÔÑ¡ÔñÆäËüµÄ¹¤¾ß¡£ 14.6.3 MP3 ±àÂë ÏÖÔÚ£¬¿ÉÒÔÑ¡Ôñlame Õâ¸ömp3 ±àÂëÆ÷¡£¿ÉÒÔÔÚaudio/lame ÖÐÕÒµ½¡£ µÚ5 Ò³FreeBSD ʹÓÃÊÖ²á ʹÓÃת»»µÄWAV Îļþ£¬¿ÉÒÔʹÓÃÏÂÃæµÄÃüÁî°Ñaudio01.wav ת³Éaudio01.mp3£º # lame -h -b 128 \ --tt " Foo Song Title" \ --ta " FooBar Artist" \ --tl " FooBar Album" \ --ty " 2001" \ --tc " Ripped and encoded by Foo" \ --tg " Genre" \ audio01.wav audio01.mp3 128K ÊDZê×¼µÄMP3 ±ÈÌØÂÊ¡£¶àÊýʹÓÃ160, »ò192¡£¸ü¸ßµÄ±ÈÌØÂÊ£¬¿ÉÄÜÐèÒª¸ü¶àµÄ´Å Å̿ռ䡣-h Ñ¡Ïî¿ÉÒÔ´ò¿ª¡°higher quality but a little slower¡±Ä£Ê½¡£ 14.6.4 MP3 ½âÂë ΪÁË°Ñmp3 ת³ÉCD£¬ËüÃDZØÐ뱻ת³É²»±»Ñ¹ËõµÄWAV ¸ñʽ¡£XMMS ºÍmpg123 ¶¼Ö§³ÖÕâЩ¡£ ÔÚXMMS ÖÐдÈë´ÅÅÌ£º 1. ÔËÐÐXMMS. 2. ÔÚ´°¿ÚÉϵ¥»÷ÓÒ¼ü´ò¿ªXMMS ²Ëµ¥¡£ 3. ÔÚOptions ÖÐÑ¡ÔñPreference¡£ 4. ¸Ä±äOutput Plugin ΪDisk Writer Plugin¡£ 5. ¼üÈëConfigure. 6. ¼üÈëÒ»¸öҪдµÄ·ÇѹËõÎļþµÄĿ¼¡£ 7. ´ò¿ªÒ»¸öMP3 Îļþ£¬°Ñvolume Éè³É100%£¬EQ ÉèΪ¹Ø±Õ¡£ 8. ¼üÈëPlay -- XMMS ½«ÏÔʾÕýÔÚ²¥·ÅµÄMP3 Îļþ£¬µ«Ìý²»¼ûÉùÒô¡£ËµÃ÷ËüÕýÔÚ ×ª»»MP3. µÚ6 Ò³FreeBSD ʹÓÃÊÖ²á 9. Èç¹ûÒªÌýMP3£¬¼ÇµÃ½«Output Plugin Éè»ØĬÈÏÖµ¡£ ÔÚmpg123 ÖÐд³Éstdout£º 1. Run mpg123 -s audio01.mp3 > audio01.pcm XMMS ÓÃWAV ¸ñʽдһ¸öÎļþ£¬¶ømpg123 °ÑMP3 д³ÉPCM ÒôÀÖ¸ñʽ¡£ÕâЩ¸ñʽÄÜÓà cdrecord »òburncd ³ÌÐòÀ´Ð´³ÉCDR ¹âÅÌ¡£¿ÉÒÔ¿´¿´µÚ12.6 ½ÚµÄÔÚFreeBSD ÖÐʹÓÃCD burner¡£ µÚ7 Ò³ |