I used the uda1341 audio chip in the Development Board, followed by the standard IIS bus. in Linux, the support for IIS and uda1341 has been improved, we only need to set the corresponding IIS pin as the pin of the schematic design of our development board.
1. The configuration of the makemenuconfig sound card is as follows:
Device Drivers
<*> Sound card support
<*> Advanced Linux sound architecture
<*> ALSA for SOC audiosupport-à
<*> SOC audiofor the Samsung s3c24xxchips
<*> SOC i2saudio support uda134x wired to a s3c24xx
2. Configure the Sound Card Driver
Here is where I modified it on the mach-smdk2440.c:
...
# Include <sound/s3c24xx_uda134x.h> // Add this header file
...
Static struct s3c24xx_uda134x_platform_data s3c24xx_uda134x_data =
{
. L3_clk = s3c2410_gpg (10), // these three pins are determined by the hardware connection of your own Development Board.
. L3_data = s3c2410_gpg (11), // three lines are required for the L3 interface: Clock, data, and Mode Selection Line.
. L3_mode = s3c2410_gpg (9 ),
. Model = uda134x_uda1341,
};
Static struct platform_device s3c24xx_uda134x =
{
. Name = "s3c24xx_uda134x ",
. Dev =
{
. Platform_data = & s3c24xx_uda134x_data,
}
};
Static struct platform_device * smdk2440_devices [] _ initdata =
{
& Initi_device_usb,
& Amp; cloud_device_ LCD,
& Amp; cloud_device_wdt,
& Amp; cloud_device_i2c0,
& Amp; cloud_device_iis,
& Amp; cloud_device_rtc,
& Amp; s3c24xx_uda134x,
};
3. Compile and download
Make zimage in the kernel directory and then burn the generated kernel file to the Development Board.
4. Test
After the development board is started, insert the USB flash drive that has copied the songs into the USB interface of the Development Board. After mounting the USB flash drive, run the "cat 01.mp3>/dev/DSP" command and you will hear the audio headset Output Audio audio, verify that the sound card driver is configured successfully.