<?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>Kinetis Microcontrollers中的主题 Re: Loopback in uart using DMA is not working as expected.</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1539835#M64183</link>
    <description>&lt;P&gt;Used status register to wait until transmission complete and reception but still having same issue..&lt;/P&gt;</description>
    <pubDate>Wed, 19 Oct 2022 06:54:43 GMT</pubDate>
    <dc:creator>madhavaishriram</dc:creator>
    <dc:date>2022-10-19T06:54:43Z</dc:date>
    <item>
      <title>Loopback in uart using DMA is not working as expected.</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1531429#M64107</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I am using MKE15Z265VLL7 FRDM board and trying to use the DMA for uart .&lt;/P&gt;&lt;P&gt;DMA0 channel 2 for tx and DMA0 channel 3 for rx. the sequence for loopback is&amp;nbsp; to call send api and after some delay calling receive api. and tx and rx is shorted using cable.&lt;/P&gt;&lt;P&gt;if is try this sequence send-delay-receive data is not receiving on receive api.&lt;/P&gt;&lt;P&gt;But if i try the sequence receive-delay-send then data is received on receive api.&lt;/P&gt;&lt;P&gt;So please if any one is having any suggestion please let me know.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached the code snippet from nxp code.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="madhavaishriram_0-1664772674289.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/195548i92F315328CFEF6EF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="madhavaishriram_0-1664772674289.png" alt="madhavaishriram_0-1664772674289.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;with this it is not receiving any data on rx line.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="madhavaishriram_1-1664772742215.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/195549i01B76B646DAEFC45/image-size/medium?v=v2&amp;amp;px=400" role="button" title="madhavaishriram_1-1664772742215.png" alt="madhavaishriram_1-1664772742215.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;if i try this then i can see the data on rx line.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advanced.&lt;/P&gt;</description>
      <pubDate>Mon, 03 Oct 2022 04:57:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1531429#M64107</guid>
      <dc:creator>madhavaishriram</dc:creator>
      <dc:date>2022-10-03T04:57:24Z</dc:date>
    </item>
    <item>
      <title>Re: Loopback in uart using DMA is not working as expected.</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1532209#M64113</link>
      <description>&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/187233"&gt;@madhavaishriram&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;I am Miguel, I will support you with your case.&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;This issue could be that the UART buffer is full, this could be why sending-delay-reading doesn’t work and receiving-delay-send works fine. You could try changing the logic on your code and make more use of the registers flags to make sure the buffer and DMA are ready to transmit and receive data.&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;You can verify that the buffer is empty with the peripherals tool on DATA register or you could validate the flags (check reference manual, TC, RDRF, TDRE) on the STAT register.&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Let us know if this resolve your issue.&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Best regards,&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Miguel.&lt;/P&gt;</description>
      <pubDate>Tue, 04 Oct 2022 15:13:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1532209#M64113</guid>
      <dc:creator>Miguel04</dc:creator>
      <dc:date>2022-10-04T15:13:35Z</dc:date>
    </item>
    <item>
      <title>Re: Loopback in uart using DMA is not working as expected.</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1539835#M64183</link>
      <description>&lt;P&gt;Used status register to wait until transmission complete and reception but still having same issue..&lt;/P&gt;</description>
      <pubDate>Wed, 19 Oct 2022 06:54:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1539835#M64183</guid>
      <dc:creator>madhavaishriram</dc:creator>
      <dc:date>2022-10-19T06:54:43Z</dc:date>
    </item>
    <item>
      <title>Re: Loopback in uart using DMA is not working as expected.</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1542043#M64199</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/187233"&gt;@madhavaishriram&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you help me verifying that the data buffer is empty before sending data (RDRF and TDRE).&lt;/P&gt;
&lt;P&gt;I'll be investigating more about your issue.&lt;/P&gt;
&lt;P&gt;Miguel.&lt;/P&gt;</description>
      <pubDate>Fri, 21 Oct 2022 15:05:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Loopback-in-uart-using-DMA-is-not-working-as-expected/m-p/1542043#M64199</guid>
      <dc:creator>Miguel04</dc:creator>
      <dc:date>2022-10-21T15:05:53Z</dc:date>
    </item>
  </channel>
</rss>

