TI中文支持网
TI专业的中文技术问题搜集分享网站

am5728音频没有输出

am5728音频的Codec使用的和参考板同样的芯片tlv320aic3104,

开机启动打印信息提示没有发现声卡,无法播放声音:

root@am57xx-evm:/dev/snd# amixer controlsroot@am57xx-evm:/dev/snd# amixer scontrols
root@am57xx-evm:/dev/snd# dmesg | grep "sound"
[ 2.874910] No soundcards found.
[ 9.126852] of_get_named_gpiod_flags: can't parse 'simple-audio-card,hp-det-gpio' property of node '/sound@0[0]'
[ 9.126863] of_get_named_gpiod_flags: can't parse 'simple-audio-card,mic-det-gpio' property of node '/sound@0[0]'
[ 9.126887] asoc-simple-card sound@0: cannot find the slot for index 0 (range 0-0), error: -16
[ 9.139684] asoc-simple-card sound@0: ASoC: can't create sound card for card BeagleBoard-X15: -16
[ 9.162229] asoc-simple-card: probe of sound@0 failed with error -16

下面是开发板的原理图:

设备树如下:

/ {
model = "TI AM5728 BeagleBoard-X15";
compatible = "ti,am572x-beagle-x15", "ti,am5728", "ti,dra742", "ti,dra74", "ti,dra7";

aliases {
rtc0 = &mcp_rtc;
rtc1 = &tps659038_rtc;
rtc2 = &rtc;
display0 = &hdmi0;

sound0 = &sound0;
//sound1 = &hdmi;
};

vdd_3v3: fixedregulator-vdd_3v3 {
compatible = "regulator-fixed";
regulator-name = "vdd_3v3";
vin-supply = <&regen1>;
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
};

aic_dvdd: fixedregulator-aic_dvdd {
compatible = "regulator-fixed";
regulator-name = "aic_dvdd_fixed";
vin-supply = <&vdd_3v3>;
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
};

sound0: sound@0 {
compatible = "simple-audio-card";
simple-audio-card,name = "BeagleBoard-X15";
simple-audio-card,widgets =
"Line", "Line Out",
"Line", "Line In";
simple-audio-card,routing =
"Line Out", "LLOUT",
"Line Out", "RLOUT",
"MIC2L", "Line In",
"MIC2R", "Line In";
simple-audio-card,format = "dsp_b";
simple-audio-card,bitclock-master = <&sound0_master>;
simple-audio-card,frame-master = <&sound0_master>;
simple-audio-card,bitclock-inversion;

simple-audio-card,cpu {
sound-dai = <&mcasp2>;
/*
sound-dai = <&mcasp3>;
*/
};

sound0_master: simple-audio-card,codec {
sound-dai = <&tlv320aic3104>;
clocks = <&ref_clkin1_ck>;
/*
clocks = <&clkout2_clk>;
*/
};
};
};

&i2c4 {
status = "okay";
clock-frequency = <400000>;

tlv320aic3104: tlv320aic3104@18 {
#sound-dai-cells = <0>;
compatible = "ti,tlv320aic3104";
reg = <0x18>;

assigned-clocks = <&ref_clkin1_ck>;

adc-settle-ms = <40>;
AVDD-supply = <&vdd_3v3>;
IOVDD-supply = <&vdd_3v3>;
DRVDD-supply = <&vdd_3v3>;
DVDD-supply = <&aic_dvdd>;

status = "okay";
};

};

&mcasp2 {
#sound-dai-cells = <0>;
assigned-clocks = <&mcasp2_ahclkx_mux>;
assigned-clock-parents = <&sys_clkin2>;
status = "okay";

op-mode = <0>; /* MCASP_IIS_MODE */
tdm-slots = <2>;
/* 4 serializers */
serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
1 2 0 0
>;
tx-num-evt = <32>;
rx-num-evt = <32>;
};

Jian Zhou:

内核配置有确定加载声卡驱动么?

ce guo:

回复 Jian Zhou:

我的内核是有加载声卡驱动的,

make menuconfig

Device Drivers--->Sound card support--->Advanced Linux Sound Architecture--->ALSA for SoC audio support--->
<M> SoC Audio for the Atmel System-on-Chip<*>SoC Audio for the Texas Instruments OMAP chips<*>SoC Audio for Texas Instruments chips using eDMA<*>Multichannel Audio Serial Port (McASP) support
<M>   HDMI audio support for OMAP4+ based SoCsCODEC drivers---><M> Texas Instruments TLV320AIC3x CODECs<M>ASoC Simple sound card support

执行lsmod命令显示加载了下面三个模块:

snd_soc_simple_card 7896 0snd_soc_simple_card 7896 0

snd_soc_tlv320aic3x    48966  0

因为tlv320aic3x芯片的复位引脚修改为了gpio引脚,把相应GPIO引脚拉高然后才加载的snd_soc_tlv320aic3x.ko

加载snd_soc_tlv320aic3x.ko的同时有一下错误信息:

[ 81.647879] vdd_3v3: supplied by regen1[ 81.652274] aic_dvdd_fixed: supplied by vdd_3v3

[ 81.685263] asoc-simple-card sound@0: cannot find the slot for index 0 (range 0-0), error: -16[ 81.694418] asoc-simple-card sound@0: ASoC: can't create sound card for cardBeagleBoard-X15: -16[ 81.703732] asoc-simple-card: probe of sound@0 failed with error -16

ce guo:

回复 Jian Zhou:

你好,我通过上述的设备树,MCLK引脚没有时钟输出,

sound card创建失败

赞(0)
未经允许不得转载:TI中文支持网 » am5728音频没有输出
分享到: 更多 (0)