<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>i.MX ProcessorsのトピックSAI padding bits configuration on imx93</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414378#M246759</link>
    <description>&lt;P&gt;I'm having a hard time correctly configuring the sai link between the imx and the codec under linux.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The codec is an AK4619, used in 4 channels TDM mode. Playback is ok at 48KHz / 32 bits TDM mode, MSB first and MSB justified.&lt;/P&gt;&lt;P&gt;For capture, the AK4619 only supports 24 bits. The data is MSB justified, which means that non significant bits comes &lt;STRONG&gt;after&lt;/STRONG&gt;&amp;nbsp;the relevant bits (significative bits are 8-31). On the other side, the sai sets the FBT to 23, which means that the significative bits are 0-23.&lt;/P&gt;&lt;P&gt;I tried to find the relevant settings, but could not. I understand that FBT tells where the relevant data starts, but i can't find which register sets the data size (which, in my case, is 24, as opposed to the word size which is 32).&lt;/P&gt;&lt;P&gt;What register needs to be set, or what config must be set in the device tree ? Here's the relevant config i actually use :&lt;/P&gt;&lt;PRE&gt;&amp;amp;sai3 {&lt;BR /&gt;#sound-dai-cells = &amp;lt;0&amp;gt;;&lt;BR /&gt;clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3_IPG&amp;gt;, &amp;lt;&amp;amp;clk IMX93_CLK_DUMMY&amp;gt;,&lt;BR /&gt;&amp;lt;&amp;amp;clk IMX93_CLK_SAI3_GATE&amp;gt;, &amp;lt;&amp;amp;clk IMX93_CLK_DUMMY&amp;gt;,&lt;BR /&gt;&amp;lt;&amp;amp;clk IMX93_CLK_DUMMY&amp;gt;, &amp;lt;&amp;amp;clk IMX93_CLK_AUDIO_PLL&amp;gt;;&lt;BR /&gt;clock-names = "bus", "mclk0", "mclk1", "mclk2", "mclk3", "pll8k";&lt;BR /&gt;assigned-clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3&amp;gt;;&lt;BR /&gt;pinctrl-names = "default";&lt;BR /&gt; pinctrl-0 = &amp;lt;&amp;amp;pinctrl_sai3&amp;gt;;&lt;BR /&gt;  assigned-clock-parents = &amp;lt;&amp;amp;clk IMX93_CLK_AUDIO_PLL&amp;gt;;&lt;BR /&gt;  assigned-clock-rates = &amp;lt;24576000&amp;gt;;&lt;BR /&gt;  fsl,sai-mclk-direction-output;&lt;BR /&gt;  fsl,sai-asynchronous;&lt;BR /&gt;&lt;BR /&gt;  status = "okay";&lt;BR /&gt;};&lt;BR /&gt;simple-audio-card,dai-link {&lt;BR /&gt;   link-name = "AK-4CHANNELS";&lt;BR /&gt;   format = "i2s";&lt;BR /&gt;   dai-tdm-slot-num = &amp;lt;4&amp;gt;;&lt;BR /&gt;   dai-tdm-slot-width = &amp;lt;32&amp;gt;;&lt;BR /&gt;   fsl,mclk-equal-bclk;&lt;BR /&gt;   cpu {&lt;BR /&gt;      sound-dai = &amp;lt;&amp;amp;sai3&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-num = &amp;lt;4&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-width = &amp;lt;32&amp;gt;;&lt;BR /&gt;      assigned-clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3&amp;gt;;&lt;BR /&gt;   };&lt;BR /&gt;   codec {&lt;BR /&gt;   sound-dai = &amp;lt;&amp;amp;ak4619&amp;gt;;&lt;BR /&gt;      system-clock-frequency = &amp;lt;24576000&amp;gt;;&lt;BR /&gt;      assigned-clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-num = &amp;lt;4&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-width = &amp;lt;32&amp;gt;;&lt;BR /&gt;   };&lt;BR /&gt;};&lt;/PRE&gt;&lt;P&gt;I've checked with a scope, and the data on the sai line looks correct.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any hints on this would be really appreciated.&lt;/P&gt;</description>
    <pubDate>Thu, 17 Sep 2026 16:08:32 GMT</pubDate>
    <dc:creator>julienblanc</dc:creator>
    <dc:date>2026-09-17T16:08:32Z</dc:date>
    <item>
      <title>SAI padding bits configuration on imx93</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414378#M246759</link>
      <description>&lt;P&gt;I'm having a hard time correctly configuring the sai link between the imx and the codec under linux.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The codec is an AK4619, used in 4 channels TDM mode. Playback is ok at 48KHz / 32 bits TDM mode, MSB first and MSB justified.&lt;/P&gt;&lt;P&gt;For capture, the AK4619 only supports 24 bits. The data is MSB justified, which means that non significant bits comes &lt;STRONG&gt;after&lt;/STRONG&gt;&amp;nbsp;the relevant bits (significative bits are 8-31). On the other side, the sai sets the FBT to 23, which means that the significative bits are 0-23.&lt;/P&gt;&lt;P&gt;I tried to find the relevant settings, but could not. I understand that FBT tells where the relevant data starts, but i can't find which register sets the data size (which, in my case, is 24, as opposed to the word size which is 32).&lt;/P&gt;&lt;P&gt;What register needs to be set, or what config must be set in the device tree ? Here's the relevant config i actually use :&lt;/P&gt;&lt;PRE&gt;&amp;amp;sai3 {&lt;BR /&gt;#sound-dai-cells = &amp;lt;0&amp;gt;;&lt;BR /&gt;clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3_IPG&amp;gt;, &amp;lt;&amp;amp;clk IMX93_CLK_DUMMY&amp;gt;,&lt;BR /&gt;&amp;lt;&amp;amp;clk IMX93_CLK_SAI3_GATE&amp;gt;, &amp;lt;&amp;amp;clk IMX93_CLK_DUMMY&amp;gt;,&lt;BR /&gt;&amp;lt;&amp;amp;clk IMX93_CLK_DUMMY&amp;gt;, &amp;lt;&amp;amp;clk IMX93_CLK_AUDIO_PLL&amp;gt;;&lt;BR /&gt;clock-names = "bus", "mclk0", "mclk1", "mclk2", "mclk3", "pll8k";&lt;BR /&gt;assigned-clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3&amp;gt;;&lt;BR /&gt;pinctrl-names = "default";&lt;BR /&gt; pinctrl-0 = &amp;lt;&amp;amp;pinctrl_sai3&amp;gt;;&lt;BR /&gt;  assigned-clock-parents = &amp;lt;&amp;amp;clk IMX93_CLK_AUDIO_PLL&amp;gt;;&lt;BR /&gt;  assigned-clock-rates = &amp;lt;24576000&amp;gt;;&lt;BR /&gt;  fsl,sai-mclk-direction-output;&lt;BR /&gt;  fsl,sai-asynchronous;&lt;BR /&gt;&lt;BR /&gt;  status = "okay";&lt;BR /&gt;};&lt;BR /&gt;simple-audio-card,dai-link {&lt;BR /&gt;   link-name = "AK-4CHANNELS";&lt;BR /&gt;   format = "i2s";&lt;BR /&gt;   dai-tdm-slot-num = &amp;lt;4&amp;gt;;&lt;BR /&gt;   dai-tdm-slot-width = &amp;lt;32&amp;gt;;&lt;BR /&gt;   fsl,mclk-equal-bclk;&lt;BR /&gt;   cpu {&lt;BR /&gt;      sound-dai = &amp;lt;&amp;amp;sai3&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-num = &amp;lt;4&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-width = &amp;lt;32&amp;gt;;&lt;BR /&gt;      assigned-clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3&amp;gt;;&lt;BR /&gt;   };&lt;BR /&gt;   codec {&lt;BR /&gt;   sound-dai = &amp;lt;&amp;amp;ak4619&amp;gt;;&lt;BR /&gt;      system-clock-frequency = &amp;lt;24576000&amp;gt;;&lt;BR /&gt;      assigned-clocks = &amp;lt;&amp;amp;clk IMX93_CLK_SAI3&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-num = &amp;lt;4&amp;gt;;&lt;BR /&gt;      dai-tdm-slot-width = &amp;lt;32&amp;gt;;&lt;BR /&gt;   };&lt;BR /&gt;};&lt;/PRE&gt;&lt;P&gt;I've checked with a scope, and the data on the sai line looks correct.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any hints on this would be really appreciated.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2026 16:08:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414378#M246759</guid>
      <dc:creator>julienblanc</dc:creator>
      <dc:date>2026-09-17T16:08:32Z</dc:date>
    </item>
    <item>
      <title>Re: SAI padding bits configuration on imx93</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414421#M246761</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Did you try to use -f S32_LE with ALSA during recording/playback?&lt;/P&gt;
&lt;P&gt;This configuration is not done in device tree, if you want to configure it from the driver, you need to modify register TCR5/RCR5 here:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/nxp-imx/linux-imx/blob/b096ce610e956cc2596006343df8a2a26ed6e019/sound/soc/fsl/fsl_sai.h" target="_blank"&gt;https://github.com/nxp-imx/linux-imx/blob/b096ce610e956cc2596006343df8a2a26ed6e019/sound/soc/fsl/fsl_sai.h&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/nxp-imx/linux-imx/blob/b096ce610e956cc2596006343df8a2a26ed6e019/sound/soc/fsl/fsl_sai.c" target="_blank"&gt;https://github.com/nxp-imx/linux-imx/blob/b096ce610e956cc2596006343df8a2a26ed6e019/sound/soc/fsl/fsl_sai.c&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Best regards.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2026 22:08:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414421#M246761</guid>
      <dc:creator>JorgeCas</dc:creator>
      <dc:date>2026-09-17T22:08:11Z</dc:date>
    </item>
    <item>
      <title>Re: SAI padding bits configuration on imx93</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414526#M246770</link>
      <description>&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;The problem is that i don't know what to write in this register. The only doc i can find is&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="julienblanc_0-1789720432684.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/396561iC297B84EEFD25F15/image-size/medium?v=v2&amp;amp;px=400" role="button" title="julienblanc_0-1789720432684.png" alt="julienblanc_0-1789720432684.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I've highlighted the relevant line in my case. So yes, i should write 0b11111 in FBT, but how do i tell that only 24 bits are relevant ? My understanding is that i cannot use W0W and WNW as they tell the word size, which in my case is 32 bits. In can't find anything relevant in neither of the RCRx registers.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Julien&lt;/P&gt;</description>
      <pubDate>Fri, 18 Sep 2026 08:40:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414526#M246770</guid>
      <dc:creator>julienblanc</dc:creator>
      <dc:date>2026-09-18T08:40:13Z</dc:date>
    </item>
    <item>
      <title>Re: SAI padding bits configuration on imx93</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414627#M246772</link>
      <description>&lt;P&gt;Actually, it seems that the extra bits do not cause any issue. I could get audio to work correctly after altering the driver to write the correct value in FBT.&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;</description>
      <pubDate>Fri, 18 Sep 2026 13:08:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/SAI-padding-bits-configuration-on-imx93/m-p/2414627#M246772</guid>
      <dc:creator>julienblanc</dc:creator>
      <dc:date>2026-09-18T13:08:11Z</dc:date>
    </item>
  </channel>
</rss>

