<?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>topic Re: Using 24-bit I2S data format in MCUXpresso SDK</title>
    <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1581018#M4136</link>
    <description>&lt;P&gt;The LEFTJUST setting didn't seem to be doing anything. All of my data comes from a lookup table anyway, so I just rebuilt the table with right-justified data.&lt;/P&gt;&lt;P&gt;I guess just consider this a documentation request, to clarify the data format options with a diagram like the Kinetis equivalent has.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;</description>
    <pubDate>Wed, 11 Jan 2023 17:02:35 GMT</pubDate>
    <dc:creator>scottm</dc:creator>
    <dc:date>2023-01-11T17:02:35Z</dc:date>
    <item>
      <title>Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1577629#M4113</link>
      <description>&lt;P&gt;I'm attempting to use the MCUX SDK i2s_dma_driver to send 24-bit frames on an LPC55S69 and I'm running into trouble. The code I'm working on is being ported from the MK22FN1M0 but doesn't use the SDK. The LPC55S69 user's manual is less clear than the Kinetis manual when it comes to describing I2S data formats. The SDK manual has virtually no explanation.&lt;/P&gt;&lt;P&gt;To match the Kinetis version, what I'm attempting to do is to send a buffer of single-channel, 24-bit frames. The source data is stored in a buffer of 32-bit integers, left justified. I can't find any combination of settings that gives me the results I expect, and I'm concerned about the fact that the TX function takes the number of&amp;nbsp;&lt;EM&gt;bytes&lt;/EM&gt;&amp;nbsp;and not frames or words. It's not clear what it's counting.&lt;/P&gt;&lt;P&gt;I'm testing with a repeating value of 0xffffff00 and the expected result is the data line staying high for the whole transmission. The leftJust setting seems to have no effect on the results.&lt;/P&gt;&lt;P&gt;Any idea how this should be set up?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2023 04:13:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1577629#M4113</guid>
      <dc:creator>scottm</dc:creator>
      <dc:date>2023-01-05T04:13:53Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1578242#M4115</link>
      <description>Hi,
As you know there is LEFTJUST bit is located at bit 9 of CFG1, I copy it here:
LEFTJUST Left justify data. 0
0 Data is transferred between the FIFO and the I2S serializer/deserializer right
justified, i.e. starting from bit 0 and continuing to the position defined by
DATALEN. It would correspond to right justified data in the stream on the data
bus.
1 Data is transferred between the FIFO and the I2S serializer/deserializer left
justified, i.e. starting from the MSB of the FIFO entry and continuing for the
number of bits defined by DATALEN. It would correspond to left justified data in
the stream on the data bus.

But the LEFTJUST bit just takes effect on the condition that the Data length is NOT equal to the Frame Length. Let's consider the normal I2S case that there are two slots, each slot consists of 32 bit clocks, in other words, there are 64 bits clocks in one I2S cycle, and the data length is 24 bits in each slot, in the case, assume the LEFTJUST is cleared, and the data in FIFOWR is 0xFFFFFF00, the 24 bits valid data will be 0xFFFF00. Assume the LEFTJUST is set, and the data in FIFOWR is 0xFFFFFF00, the valid data will be 0xFFFFFF. 
If the frame length is equal to the data length for example all of them are 32 bits, in the case all 32 bits data in FIFOWR are valid, and will output to data pin, the  LEFTJUST bit is useless.

Hope it can help you
BR
XiangJun Rong</description>
      <pubDate>Fri, 06 Jan 2023 01:56:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1578242#M4115</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2023-01-06T01:56:34Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1578248#M4116</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;What would really help me is if you could give this in terms of the SDK driver. The driver doesn't expose FIFOWR and the I2S DMA driver in particular is lacking any description of how it actually passes data to the I2S module.&lt;/P&gt;&lt;P&gt;My input buffer is composed of 32-bit values of which only the high 24 bits are significant. I need to send just those 24 bits per word. What settings do I use for the SDK driver to accomplish that?&lt;/P&gt;&lt;P&gt;It's not urgent now because I've worked around it by modifying my data to be right-justified but I'd still like to understand what's going on.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;</description>
      <pubDate>Fri, 06 Jan 2023 02:10:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1578248#M4116</guid>
      <dc:creator>scottm</dc:creator>
      <dc:date>2023-01-06T02:10:07Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1579771#M4133</link>
      <description>&lt;P&gt;Hi, Scott,&lt;/P&gt;
&lt;P&gt;You can configure the LEFTJUST bit with the driver for tramsmitter:&lt;/P&gt;
&lt;P&gt;static i2s_config_t s_TxConfig;&lt;BR /&gt;static i2s_config_t s_RxConfig;&lt;/P&gt;
&lt;P&gt;I2S_TxGetDefaultConfig(&amp;amp;s_TxConfig);&lt;BR /&gt;s_TxConfig.divider = DEMO_I2S_CLOCK_DIVIDER;&lt;BR /&gt;s_TxConfig.masterSlave = DEMO_I2S_TX_MODE;&lt;BR /&gt;s_TxConfig.leftJust=true;&lt;/P&gt;
&lt;P&gt;I2S_TxInit(DEMO_I2S_TX, &amp;amp;s_TxConfig);&lt;/P&gt;
&lt;P&gt;You can configure the LEFTJUST bit with the driver for receiver:&lt;/P&gt;
&lt;P&gt;I2S_RxGetDefaultConfig(&amp;amp;s_RxConfig);&lt;BR /&gt;s_RxConfig.divider = DEMO_I2S_CLOCK_DIVIDER;&lt;BR /&gt;s_RxConfig.masterSlave = DEMO_I2S_RX_MODE;&lt;/P&gt;
&lt;P&gt;s_RxConfig.leftJust=true; //true:left justified data, false:right justfied data&lt;/P&gt;
&lt;P&gt;I2S_RxInit(DEMO_I2S_RX, &amp;amp;s_RxConfig);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope it can help you&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2023 06:18:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1579771#M4133</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2023-01-10T06:18:25Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1581018#M4136</link>
      <description>&lt;P&gt;The LEFTJUST setting didn't seem to be doing anything. All of my data comes from a lookup table anyway, so I just rebuilt the table with right-justified data.&lt;/P&gt;&lt;P&gt;I guess just consider this a documentation request, to clarify the data format options with a diagram like the Kinetis equivalent has.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;</description>
      <pubDate>Wed, 11 Jan 2023 17:02:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1581018#M4136</guid>
      <dc:creator>scottm</dc:creator>
      <dc:date>2023-01-11T17:02:35Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1919017#M4860</link>
      <description>&lt;P&gt;Any Updates here? Working on s similar issue with FreeRTOS USB speker demo wanted Audio stream to work with 24bit 48khz. Was able to to get 32 bit and 16bit working fine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="vishal_roy_0-1722224939284.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/290656i37481159719A5AEF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="vishal_roy_0-1722224939284.png" alt="vishal_roy_0-1722224939284.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Will above be the root cause?&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2024 03:49:16 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/1919017#M4860</guid>
      <dc:creator>vishal_roy</dc:creator>
      <dc:date>2024-07-29T03:49:16Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/2062172#M5092</link>
      <description>Any luck with this? I'm in the same boat -- need to do 24-bit transfers but LEFTJUST doesn't seem to be doing anything.</description>
      <pubDate>Fri, 14 Mar 2025 15:03:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/2062172#M5092</guid>
      <dc:creator>sfenwick76</dc:creator>
      <dc:date>2025-03-14T15:03:31Z</dc:date>
    </item>
    <item>
      <title>Re: Using 24-bit I2S data format</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/2062176#M5093</link>
      <description>&lt;P&gt;The DMA on this LPC part does not support 24bit transfers. So you will have to manually zero pad your frames to either support 16/32 bit and configure your codec accordingly. This solved it for us.&lt;/P&gt;</description>
      <pubDate>Fri, 14 Mar 2025 15:08:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/Using-24-bit-I2S-data-format/m-p/2062176#M5093</guid>
      <dc:creator>vishal_roy</dc:creator>
      <dc:date>2025-03-14T15:08:26Z</dc:date>
    </item>
  </channel>
</rss>

