Hi everybody,I have a board with audio chip TLV320AIC23BPW.My CPU is IMX6Q. And with the connection like this
connection of the codec:
i.mx6q <--> tlv320aic23b(pin)
AUD3_TXFS LRCIN(5), LRCOUT(7)
AUD3_TXD DIN(4)
AUD3_RXD DOUT(6)
AUD3_TXC BCLK(3)
CCM_CLKO XTI(25)
I2C2_SDA SDIN(23)
I2C2_SCL SCLK(24)
I used ubuntu12.04 ltib L3.0.35_4.1.0_130816_source.tar.gz for compile
I followed How to enable TLV320 on IMX6Q?,but still not work.
always appera
ALSA devices list:
no sound cards found
in the bootmessage.
What should I do for this?
I have my /arch/arm/mach-mx6/board-mx6q-serbesd.c and /sound/soc/imx/imx-sgtl5000.c below.
Original Attachment has been moved to: board-mx6q_sabresd.c.txt.zip
Original Attachment has been moved to: imx-sgtl5000.c.txt.zip
已解决! 转到解答。
Hello, I think you need to remove unnecessary code
static int __init imx_sgtl5000_init(void)
{
int ret;
ret = platform_driver_register(&imx_sgtl5000_audio_driver);
if (ret)
return -ENOMEM;
-- if (cpu_is_mx6q())
-- imx_sgtl5000_dai[0].codec_name = "tlv320aic23-codec.0-001a";
-- else
imx_sgtl5000_dai[0].codec_name = "tlv320aic23-codec.1-001a";
because in your case, the codec is always on the same i2c bus
static struct i2c_board_info mxc_i2c1_board_info[] __initdata = {
/***************************************************************/
{
I2C_BOARD_INFO("tlv320aic23", 0x1a),
},
/****************************************************************/
Alexander
so, on your board, is the pins you used like this?
CSI0_DAT4 -> AUD3_TXFS
CSI0_DAT5 -> AUD3_TXD
CSI0_DAT6 -> AUD3_RXD
CSI0_DAT7 -> AUD3_TXC
GPIO_0 -> CCM_CLKO
KEY_COL3 -> I2C2_SDA
KEY_ROW3 -> I2C2_SCL
Seems you all settings are correct.
Did you select the SND_SOC_IMX_SGTL5000 in the kernel?
According to Alex's answer from How to enable TLV320 on IMX6Q?
===================================================
To achieve all this, ASoC basically splits an embedded audio system into 3 components:
already in the Linux kernel, selected by "select SND_SOC_TLV320AIC23" in sound/soc/imx/Kconfig
already in the Linux kernel, selected by "select SND_MXC_SOC_MX2" in sound/soc/imx/Kconfig
finally, we need a small portion of the initialization (arch/arm/mach-mx6/board-mx6q_xxx.c) and the "glue" (sound/soc/imx/imx-xxx.c), I gave an example of how we did it
I have insert some printk in the sound/soc/codecs/tlv320aic23.c ,it seems like the tlv320aic23_modinit and tlv320aic23_codec_probe is probe successful ,but the tlv320aic23_probe has not probed.
I have insert these in the tlv320aic23.c
ln 623 printk("tlv320aic23 controls!\n");
ln 719 printk("tlv320aic23 probe!ret=%d\n",ret);
ln 754 printk("tlv320aic23 init!\n");
but in my dmesg I cannot find the "tlv320aic23 controls!"
is there any where I have not set well?
Hello, I think you need to remove unnecessary code
static int __init imx_sgtl5000_init(void)
{
int ret;
ret = platform_driver_register(&imx_sgtl5000_audio_driver);
if (ret)
return -ENOMEM;
-- if (cpu_is_mx6q())
-- imx_sgtl5000_dai[0].codec_name = "tlv320aic23-codec.0-001a";
-- else
imx_sgtl5000_dai[0].codec_name = "tlv320aic23-codec.1-001a";
because in your case, the codec is always on the same i2c bus
static struct i2c_board_info mxc_i2c1_board_info[] __initdata = {
/***************************************************************/
{
I2C_BOARD_INFO("tlv320aic23", 0x1a),
},
/****************************************************************/
Alexander