<?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>S32KのトピックS32K312 DMA+IDLE+UART</title>
    <link>https://community.nxp.com/t5/S32K/S32K312-DMA-IDLE-UART/m-p/2011046#M44094</link>
    <description>&lt;P&gt;Hello, I encountered some issues while trying to receive using DMA+IDLE+UART.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At present, it is determined whether to receive by polling the IDLE status bit, but there are problems .For example, when the received length is too long, it is necessary to wait for time to determine the IDLE bit, so that DMA can transfer all the data and assign the remaining length value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I have the following question:&lt;/P&gt;&lt;P&gt;1.UART does not enter the configured UART RX callback function after configuring DMA reception. Unless it is done through DMA's rx callback. Is there a problem with my configuration?&lt;/P&gt;&lt;P&gt;2. I noticed that DMA interrupts need to be fully buffered or at least half buffered before entering the ISR function. Is there any other way to enter DMA ISR?&lt;/P&gt;</description>
    <pubDate>Tue, 10 Dec 2024 12:02:50 GMT</pubDate>
    <dc:creator>guoweifeng</dc:creator>
    <dc:date>2024-12-10T12:02:50Z</dc:date>
    <item>
      <title>S32K312 DMA+IDLE+UART</title>
      <link>https://community.nxp.com/t5/S32K/S32K312-DMA-IDLE-UART/m-p/2011046#M44094</link>
      <description>&lt;P&gt;Hello, I encountered some issues while trying to receive using DMA+IDLE+UART.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At present, it is determined whether to receive by polling the IDLE status bit, but there are problems .For example, when the received length is too long, it is necessary to wait for time to determine the IDLE bit, so that DMA can transfer all the data and assign the remaining length value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I have the following question:&lt;/P&gt;&lt;P&gt;1.UART does not enter the configured UART RX callback function after configuring DMA reception. Unless it is done through DMA's rx callback. Is there a problem with my configuration?&lt;/P&gt;&lt;P&gt;2. I noticed that DMA interrupts need to be fully buffered or at least half buffered before entering the ISR function. Is there any other way to enter DMA ISR?&lt;/P&gt;</description>
      <pubDate>Tue, 10 Dec 2024 12:02:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K312-DMA-IDLE-UART/m-p/2011046#M44094</guid>
      <dc:creator>guoweifeng</dc:creator>
      <dc:date>2024-12-10T12:02:50Z</dc:date>
    </item>
    <item>
      <title>Re: S32K312 DMA+IDLE+UART</title>
      <link>https://community.nxp.com/t5/S32K/S32K312-DMA-IDLE-UART/m-p/2013133#M44214</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/244431"&gt;@guoweifeng&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;When configuring UART to use DMA for faster data transfer, you have to configure 2 DMA channels: one for receiving and one for transmitting data. This eliminates the need for UART callback function to differentiate between receive and transmit event. Although, if you configure a callback function for UART, while also configure DMA, the callback will always be triggered by the DMA interrupt, as it is the DMA that handles the data transfer.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;DMA interrupts are generated based on the number of bytes you specify for the data transfer. For better explanation, here is how DMA handles buffers with UART:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;FONT face="tahoma,arial,helvetica,sans-serif" color="#000000"&gt;Buffer Configuration: A memory buffer is assigned to store the data to be transmitted/received. This buffer is typically a contiguous area of memory.&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT face="tahoma,arial,helvetica,sans-serif" color="#000000"&gt;DMA Request (TX): Once the UART is configured and enabled, the DMA is set up to transfer data from the buffer to the UART for transmission. The DMA will move the data from memory directly to the UART transmission line (TX) without the need for the CPU to manage each byte of data.&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT face="tahoma,arial,helvetica,sans-serif" color="#000000"&gt;DMA Request (RX): When the UART receives data, it generates an interrupt that triggers the DMA to move the data from the UART to system memory.&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT face="tahoma,arial,helvetica,sans-serif" color="#000000"&gt;Transfer Process: The DMA begins transferring data from the memory buffer to the UART. The UART sends each byte via the transmission line in the appropriate format (e.g., 8 data bits, 1 stop bit, etc.).&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT face="tahoma,arial,helvetica,sans-serif" color="#000000"&gt;Transfer Completion: Once all data has been transmitted, the DMA notifies the CPU (e.g., via an interrupt) to take any further actions if needed, such as preparing a new set of data for transmission.&lt;/FONT&gt;&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;- RomanVR.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2024 21:28:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K312-DMA-IDLE-UART/m-p/2013133#M44214</guid>
      <dc:creator>RomanVR</dc:creator>
      <dc:date>2024-12-12T21:28:34Z</dc:date>
    </item>
  </channel>
</rss>

