LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
123
返回列表 发新帖
楼主: Debentoo Gao

在Gentoo Linux下轻松安装ALSA

[复制链接]
发表于 2004-2-8 19:35:51 | 显示全部楼层
Intel Corp. 82801BA/BAM AC'97 Audio (rev 2)
2.4.22内核里面有支持
选上intel那个声卡的选项就有声音
发表于 2004-2-8 21:45:28 | 显示全部楼层
I'm using gentoo-dev-sources-2.6.2_rc1 + kde3.2.  Basically I didn't do anything to alsa, genkernel automatically compiled alsa into the kernel (I used 'genkernel all --menuconfig' so I could see what options genkernel chose for me and if necessary I could make some changes).  Then I selected alsa as the audio device under the kde control center, suddenly I got multi-channel sound!  I've tried playing a mp3 with JuK and with Kscd playing a CD simultaneously, no problem at all.  I'm really happy with linux now, impoving everyday!
发表于 2004-2-8 22:26:27 | 显示全部楼层
用Intel Corp. 82801BA/BAM AC'97 Audio (rev 2).的兄弟
你的声卡是CMI9739芯片 六声道的吧?
用这个!
http://www.cmedia.com.tw/driver/Linux/Ac97/cmaudio-041.tar.gz
发表于 2004-2-17 15:51:20 | 显示全部楼层
Intel Corp. 82801BA/BAM AC'97 Audio (rev 2)

我的KENERL 2。4。20 内核选择 编译两个驱动 或者手工加载两个驱动也可以播放

ac97_codec.o i810_audio.o
发表于 2004-3-28 20:52:20 | 显示全部楼层
I had thought about this before after visiting an artists web site and being dismayed that the free offerings were all streaming media. It made me wonder, what if I somehow make /dev/dsp a file or something. I tried and, of course, failed. Months later, my wife planned a course lesson around a radio show she had found which was offered in this format. She was quite upset to find after arriving in class that the network was down and she couldn't get the track... I did some research and found a solution.

If you have alsa drivers (or kernel > 2.6), alsa-oss, and alsa-utils installed, then you can capture streaming media directly. NOTE: I tried this under kde-3.1 and it did not work (even after disabling artsd), but under kde-3.2+, it works fine.

Edit the .asoundrc file in your home directory to look like this:
Code:

    pcm.copy {
        type plug
        slave {
          pcm hw
        }
        route_policy copy
    }



Now, in one terminal, try playing some audio:
Code:

play /usr/kde/3.2/share/sounds/KDE_Startup.wav



In another terminal, use this command:
Code:

arecord -f cd -t wav -D copy > capture.wav


This tells the alsa record utility to use cd quality sound in wav format using your defined 'copy' pcm device and put the output in capture.wav.

You will have to hand time this or write some script to synchronize these commands, but to simply test, the terminals work fine.

OK, now for the good stuff.
Code:

realplay file.smil


In one terminal and
Code:

arecord -f cd -t wav -d copy | lame - file.mp3


in another and you have just captured your streaming media and encoded it on the fly

You may get more mileage using the aoss LD_PRELOAD wrapper for the playing application, but I found this was not neccessary for the aforementioned app, as it seems to play directly to the native sound device.

NOTE: You may also get things to work by simply using:
Code:

arecord -f cd -t wav -d hw



My sound card is es1371, BTW.

Have fun
发表于 2004-3-29 08:23:00 | 显示全部楼层
cmi9739A的声卡可以依据南桥来驱动的。
因此用模块:via82xx来驱动。
发表于 2004-3-29 08:23:43 | 显示全部楼层
多声道装alsa-oss库就好了。
发表于 2004-4-28 16:10:51 | 显示全部楼层
Error! : (
------------------------------------------
When I input that:
env ALSA_CARDS='via82xxx' emerge alsa-driver
------------------------------------------
Later...display error!
------------------------------------------
/var/tmp/portage/alsa-driver-0.9.8/work/alsa-driver-0.9.8/include/adriver.h:134: error: redefinition of `PDE'
/usr/src/linux/include/linux/proc_fs.h:267: error: `PDE' previously defined here
In file included from sgbuf.c:12:
/var/tmp/portage/alsa-driver-0.9.8/work/alsa-driver-0.9.8/include/adriver.h:134: error: redefinition of `PDE'
/usr/src/linux/include/linux/proc_fs.h:267: error: `PDE' previously defined here
memory_wrapper.c: In function `snd_compat_vmalloc_to_page':
memory_wrapper.c:33: warning: implicit declaration of function `VMALLOC_VMADDR'
memory_wrapper.c:39: warning: implicit declaration of function `pte_offset'
memory_wrapper.c:39: warning: assignment makes pointer from integer without a cast
make[1]: *** [sgbuf.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: *** [memory_wrapper.o] Error 1
make[1]: Leaving directory `/var/tmp/portage/alsa-driver-0.9.8/work/alsa-driver-0.9.8/acore'
make: *** [compile] Error 1

!!! ERROR: media-sound/alsa-driver-0.9.8 failed.
!!! Function src_compile, Line 64, Exitcode 2
!!! Parallel Make Failed
------------------------------------------------
#grep audio /proc/pci
Multimedia audio controller: VIA Technologies, Inc. VT82C686 AC97 Audio Controller (rev 80).
-------------------------------------------------
OS=Gentoo1.4 Kernel=2.6
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表