Skip to main content
Ara.1
Associate III
August 9, 2021
Question

stm32mp1 sgtl5000 codec over i2s

  • August 9, 2021
  • 2 replies
  • 1453 views

Hi All,

i am getting kernel soc sgtl5000.c error

sgtl5000 0-000a: Error reading chip id -6

any idea where am i missing , let me know if you need any further inputs

&i2c1 {

   pinctrl-names = "default", "sleep";

   pinctrl-0 = <&i2c1__pins_a>;

   pinctrl-1 = <&i2c1_sleep_pins_a>;

   /*i2c-scl-rising-time-ns = <185>;

   i2c-scl-falling-time-ns = <20>;*/

   clock-frequency = <400000>;

   status = "okay";

   /delete-property/dmas;

   /delete-property/dma-names;

   sgtl5000: codec@0a {

      compatible = "fsl,sgtl5000";

      reg = <0x0a>;

      #sound-dai-cells = <0>;

      //clocks = <&clk_ext_audio_codec>;

      clocks = <&i2s1>;

       clock-names = "MCLK1";

      VDDA-supply = <&v3v3>;

      VDDIO-supply = <&v3v3>;

      sgtl5000_port: port {

         #address-cells = <1>;

         #size-cells = <0>;

         sgtl5000_tx_endpoint: endpoint@0 {

            reg = <0>;

            remote-endpoint = <&i2s1_tx_endpoint>;

         };

         sgtl5000_rx_endpoint: endpoint@1 {

            reg = <1>;

            remote-endpoint = <&i2s1_rx_endpoint>;

         };

      };

};

&i2s1 {

   #clock-cells = <0>;

   clocks = <&rcc SPI1>, <&rcc SPI1_K>, <&rcc PLL3_Q>, <&rcc PLL3_R>;

   clock-names = "pclk", "i2sclk", "x8k", "x11k";

   pinctrl-names = "default";

   pinctrl-0 = <&i2s1_pins_mx &i2sa_pins_z>;

   status = "okay";

      i2s1_tx_port: port@0 {

         i2s1_tx_endpoint: endpoint {

            remote-endpoint = <&sgtl5000_tx_endpoint>;

            format = "i2s";

         mclk-fs = <256>;

         };

      };

      i2s1_rx_port: port@1 {

         i2s1_rx_endpoint: endpoint {

            remote-endpoint = <&sgtl5000_rx_endpoint>;

            format = "i2s";

         mclk-fs = <256>;

         };

      };

};

   sound{

       compatible = "audio-graph-card";

      routing =

         "MIC_IN", "Capture",

         "Capture", "Mic Bias",

         "Playback", "HP_OUT";

          dais = <&i2s1_tx_port &i2s1_rx_port>;

         status = "okay";

   };

This topic has been closed for replies.

2 replies

Olivier GALLIEN
Technical Moderator
September 1, 2021

Hi @Ara.1​ ,

You have posted several questions related to same problem.

We will gather all support under post : https://community.st.com/s/question/0D53W000010RjZfSAK/sgtl5000-codec-dsi-i2c

Olivier

Olivier GALLIEN In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Ara.1
Ara.1Author
Associate III
September 1, 2021

Yes i had done this as i was not getting any response on this, query, i assumed to draft in detailed way so created a new quest,