1. 簡介
- 專欄總目錄
- 本文是基于RK3588平臺,音頻芯片ES8388調試總結。
- 外接聲卡:ES8388
2. 音頻ES8388調試
2.1 調試總覽,調試步驟分析
- 步驟 ① dts配置
- 步驟 ② 編譯燒寫,調試
2.2 dts配置
-
系統(tǒng)聲音配置:
es8388_sound: es8388-sound { status = "okay"; compatible = "rockchip,multicodecs-card"; rockchip,card-name = "rockchip-es8388"; hp-det-gpio = <&gpio1 RK_PD5 GPIO_ACTIVE_LOW>; io-channels = <&saradc 3>; io-channel-names = "adc-detect"; keyup-threshold-microvolt = <1800000>; poll-interval = <100>; spk-con-gpio = <&gpio1 RK_PD3 GPIO_ACTIVE_HIGH>; hp-con-gpio = <&gpio1 RK_PD2 GPIO_ACTIVE_HIGH>; rockchip,format = "i2s"; rockchip,mclk-fs = <256>; rockchip,cpu = <&i2s0_8ch>; rockchip,codec = <&es8388>; rockchip,audio-routing = "Headphone", "LOUT1", "Headphone", "ROUT1", "Speaker", "LOUT2", "Speaker", "ROUT2", "Headphone", "Headphone Power", "Headphone", "Headphone Power", "Speaker", "Speaker Power", "Speaker", "Speaker Power", "LINPUT1", "Main Mic", "LINPUT2", "Main Mic", "RINPUT1", "Headset Mic", "RINPUT2", "Headset Mic"; pinctrl-names = "default"; pinctrl-0 = <&hp_det>; play-pause-key { label = "playpause"; linux,code = <KEY_PLAYPAUSE>; press-threshold-microvolt = <2000>; }; };
-
ES8388設備驅動配置
&i2c7 { status = "okay"; es8388: es8388@11 { status = "okay"; #sound-dai-cells = <0>; compatible = "everest,es8388", "everest,es8323"; reg = <0x11>; clocks = <&cru I2S0_8CH_MCLKOUT>; clock-names = "mclk"; assigned-clocks = <&cru I2S0_8CH_MCLKOUT>; assigned-clock-rates = <12288000>; pinctrl-names = "default"; pinctrl-0 = <&i2s0_mclk>; }; };
2.3 編譯燒寫,調試
-
查看聲卡命令:
cat /proc/asound/cards
-
將wav文件拷貝到板子上:
adb root adb remount adb push C:\adb\test.wav mnt
-
RK Android 播放音樂 ( RK Android SDK 標配 tiny-alsa 工具 ):
adb shell cd /mnt tinyplay ./test.wav -D 0 -d 0
-
RK Android 錄音:
tinycap /sdcard/test.wav 播放錄音 cd /sdcard tinyplay ./test.wav -D 0 -d 0
-
RK Linux 播放音樂 ( RK Linux SDK 標配 alsa-utils 工具 )
aplay test.wav
或者
aplay -Dplughw:0,0 test.wav aplay -Dplughw:1,0 test.wav aplay -Dplughw:2,0 test.wav -Dplughw:x 表示指定第幾個聲卡
或者文章來源:http://www.zghlxwxcb.cn/news/detail-653342.html
aplay -D plughw:CARD=rockchipes8388 test.wav
-
RK Linux 錄音文章來源地址http://www.zghlxwxcb.cn/news/detail-653342.html
arecord -D hw:1,0 -d 10 -f cd -r 44100 -c 2 -t wav test.wav -d 10表示錄制10秒聲音,test.wav是保存的文件名稱 -D hw:x 表示指定第幾個聲卡 -r 指定采樣率,-f 指定每個采樣點的位數(shù)--樣本大小
ArmSoM 產(chǎn)品介紹: http://wiki.armsom.org/index.php/ArmSoM-w3
ArmSoM 技術論壇: http://forum.armsom.org/
到了這里,關于ArmSoM-W3之RK3588 - ES8388音頻調試筆記的文章就介紹完了。如果您還想了解更多內容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關文章,希望大家以后多多支持TOY模板網(wǎng)!