TLV320AIC3100: tlv320aic31xx-codec 1-0018: Could not reset device: -6

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

TLV320AIC3100: tlv320aic31xx-codec 1-0018: Could not reset device: -6

448件の閲覧回数
ajita02
Contributor IV

Hi all,

I am using "tlv320aic3100" in our project. I am using "IMX8MM" with linux kernel 5.4.70. I am able to probe codec driver. Below is my dmesg logs.

 

[    4.267295] asoc-simple-card sound-tlv320aic: tlv320aic31xx-hifi <-> 30030000.sai mapping ok
[    4.275771] asoc-simple-card sound-tlv320aic: ASoC: no DMI vendor name!
[    4.286372] tlv320aic31xx-codec 1-0018: Could not reset device: -6

My dts file is as follows.

 sound-tlv320aic {
    compatible = "simple-audio-card";
    simple-audio-card,name = "tlv320aic-audio";
    simple-audio-card,format = "i2s";
    simple-audio-card,frame-master = <&cpudaitlv>;
    simple-audio-card,bitclock-master = <&cpudaitlv>;
    simple-audio-card,widgets =
        "Microphone", "Microphone Jack",
        "Line", "Line In Jack",
        "Line", "Line Out Jack",
        "Headphone", "Headphone Jack",
        "Speaker", "Speaker Jack";
    simple-audio-card,routing =
        "Headphone Jack", "HPL",
        "Headphone Jack", "HPR",
        "MIC1LM","Microphone Jack",
        "MIC1RP","Microphone Jack",
        "MIC1LP","Microphone Jack",
        "Speaker Jack", "SPK";

    cpudaitlv: simple-audio-card,cpu {
      sound-dai = <&sai3>;
      clocks = <&clk IMX8MM_CLK_SAI3_ROOT>;
      dai-tdm-slot-num = <2>;
      dai-tdm-slot-width = <32>; 
    };

    simple-audio-card,codec {
        sound-dai = <&tlv320aic>;
        clocks = <&clk IMX8MM_CLK_SAI3_ROOT>;
    };
  };

&i2c2 {
    clock-frequency = <400000>;
    pinctrl-names = "default";
    pinctrl-0 = <&pinctrl_i2c2>;
    status = "okay";

  tlv320aic: tlv320aic@18 {
    #sound-dai-cells = <0>;
    compatible = "ti,tlv320aic3100";
    pinctrl-names = "default";
    pinctrl-0 = <&pinctrl_gpio_wlf>;
    ti,reset-gpio = <&gpio3 0 GPIO_ACTIVE_LOW>;
    reg=<0x18>;
    ai31xx-micbias-vg = <MICBIAS_2_0V>;
    status = "okay";
  };
};

&sai3 {
    #sound-dai-cells = <0>;
    pinctrl-names = "default";
    pinctrl-0 = <&pinctrl_sai3>;
    assigned-clocks = <&clk IMX8MM_CLK_SAI3>;
    assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL2_OUT>;
    assigned-clock-rates = <11289600>;
    status = "okay";
};

pinctrl_gpio_wlf: gpiowlfgrp {
        fsl,pins = <
            MX8MM_IOMUXC_NAND_ALE_GPIO3_IO0     0xd6
        >;
};

I am using PLL2 for SAI3 root clock with frequency of "11289600". I have also added PLL parameters for current frequency in "tlv320aic31xx.c" as follows:

{11289600,  44100,  8, 0,   128,   8,  2,   128,   8,  2},

Can you help me to resolve reset error?

タグ(3)
4 返答(返信)

226件の閲覧回数
ajita02
Contributor IV

Hi @Alejandro_Salas ,

It seems that it was loose connection problem. Thanks for reaching out. Can you give me init sequence for ADC? I want to enable mic functionality of tlv320aic3100.

Thanks & Regards,
Ajita

0 件の賞賛
返信

364件の閲覧回数
ajita02
Contributor IV

I am able to detect and write using i2c commands. I was going through tlv320dac3100 . It has init sequence written through which DAC is configured using I2C commands. By using this I can play audio on tlv320aic3100. It confirms that IC is in working state and need to configure before using it. Can you give me similar init sequence for ADC? I want to enable mic functionality. Can you share me init sequence for AIC?

Thanks,

Ajita

0 件の賞賛
返信

353件の閲覧回数
Alejandro_Salas
NXP TechSupport
NXP TechSupport

Hello @ajita02 

 

Could you please clarify is you were able to solve your reset issue?

If not, could you please check your GPIO reset pin?

The driver takes the GPIO as priority to reset the codec, you can see it here.

 

Best regards,

Salas.

0 件の賞賛
返信

423件の閲覧回数
Alejandro_Salas
NXP TechSupport
NXP TechSupport

Hello @ajita02 

 

I hope you are doing very well.

 

Could you please verify that you can read the codec from the I2C bus with i2cdetect tool on linux?

Also, please check if the reset gpio is working.

 

Best regards,

Salas.

0 件の賞賛
返信