Author: Ren chengming,Hua Qing vision embedded college lecturer.
1. Download the library required by ALSA and test tool for ALSA.
ALSA-Lib-1.0.24.1.tar.bz2w.alsa-utils-1.0.24.2.tar.bz2.
2. By default, the kernel already supports the Alsa driver. in the case of insurance, check the kernel first, for example:
Device Drivers --->
Sound Card support --->
Advanced Linux sound Architecture --->
ALSA for SOC audio support --->
<*> ASOC support for Samsung
3. Decompress ALSA-lib and ALSA-utils to configure ALSA-lib and run:
./Configure -- Host = arm-None-Linux-gnueabi --
Prefix =/home/Linux/cyg_bin/ARM/ALSA/alsa_lib
Make
Make install
Configure and run ALSA-utils:
./Configure -- Host = arm-None-Linux-gnueabi --
Prefix =/home/Linux/cyg_bin/ARM/ALSA/alsa_utils -- With-ALSA-inc-
Prefix =/home/Linux/cyg_bin/ARM/ALSA/alsa_lib/include -- With-ALSA-
Prefix =/home/Linux/cyg_bin/ARM/ALSA/alsa_lib/lib -- disable-alsamixer --
Disable-xmlto
Make
Make install
Parameter description:
-- Host specifies the platform on which the software is compiled and -- prefix specifies the path to install make install (such as include, Lib, and bin) (if a file is missing during compilation (folder) in this case, you only need to create the corresponding file (folder) and grant the 777 permission)
4. port to the Development Board
The ALSA library must be released on the Development Board. conf is released to the board. After make install, find the Alsa directory in the share directory under your installation directory and copy the directory to the Development Board.
Copy the cross-compiled application aplay to the directory corresponding to the Development Board.
Note: If you are prompted that the ALSA. conf file under a directory of XX cannot be found, you only need to follow the prompts on the Development Board to create the corresponding directory, and then test the share directory to the corresponding directory.
V. Test
Create/dev/snd in the file system and create a device node in this directory:
Test audio (playback sound ):
More free information, all in the far vision download center: http://download.farsight.com.cn/download/