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
Solved! Go to Solution.
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
Seems you didn't follow the changing mentioned in How to enable TLV320 on IMX6Q?
At least, the IOMUX setting and the I2C2 setting for your TLV320 cannot be found in your code.
Thank you for your reply.
but the IOMUX is in the board-mx6q_sabresd.h,which I have not changed.
it's a little difference between sabresd and sabrelite
can you show me your board-mx6q_sabresd.h?
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
No,it's like this
CSI0_DAT4 -> AUD3_TXC
CSI0_DAT5 -> AUD3_TXD
CSI0_DAT6 -> AUD3_TXFS
CSI0_DAT7 -> AUD3_RXD
GPIO_0 -> CCM_CLKO
KEY_COL3 -> I2C2_SCL
KEY_ROW3 -> I2C2_SDA
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
have you try to type dmesg to check whether the driver can probe successful or not?
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
Thank you ,Alexander,you are right.
I changed the file as you said,and now I can find the sound card in my dmesg.