<?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中的主题 UART0 different behaviour in debug mode</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/UART0-different-behaviour-in-debug-mode/m-p/753973#M45951</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using MKE02Z64M2 microcontroller with P&amp;amp;E cyclone debugger and CW 10.6.4. I am using UART0 in Tx &amp;amp; Rx mode. This is supposed to work in following way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Initially UART remains in Rx mode with predfined receive length of 9 bytes. As soon 9 bytes have been received data is copied to a buffer and mode is switched to Tx to tranmsitt the 8 bytes of data. After tranmission is completed the mode is switched to Rx to wait for next data packet.&lt;/P&gt;&lt;P&gt;The communication is working without any problem without debugger but when i try to debug the project i am getting always overrun error. I am able to find out the root cause of this but not sure how to fix this. The issue is different mode switch time in debug mode &amp;amp; without debugger.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Without Debugger:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;The time between packet received &amp;amp; switching to Tx mode(to send 8 bytes) is approximately 215us.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;With Debugger:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;The time between packet received &amp;amp; switching to Tx mode(to send 8 bytes) is approximately 600us.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This eventually violates the timing with master device which send packet after every 2 ms and i get overrun error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be highly appreciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 20 Apr 2018 11:30:57 GMT</pubDate>
    <dc:creator>faisalaslam</dc:creator>
    <dc:date>2018-04-20T11:30:57Z</dc:date>
    <item>
      <title>UART0 different behaviour in debug mode</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/UART0-different-behaviour-in-debug-mode/m-p/753973#M45951</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using MKE02Z64M2 microcontroller with P&amp;amp;E cyclone debugger and CW 10.6.4. I am using UART0 in Tx &amp;amp; Rx mode. This is supposed to work in following way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Initially UART remains in Rx mode with predfined receive length of 9 bytes. As soon 9 bytes have been received data is copied to a buffer and mode is switched to Tx to tranmsitt the 8 bytes of data. After tranmission is completed the mode is switched to Rx to wait for next data packet.&lt;/P&gt;&lt;P&gt;The communication is working without any problem without debugger but when i try to debug the project i am getting always overrun error. I am able to find out the root cause of this but not sure how to fix this. The issue is different mode switch time in debug mode &amp;amp; without debugger.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Without Debugger:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;The time between packet received &amp;amp; switching to Tx mode(to send 8 bytes) is approximately 215us.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;With Debugger:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;The time between packet received &amp;amp; switching to Tx mode(to send 8 bytes) is approximately 600us.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This eventually violates the timing with master device which send packet after every 2 ms and i get overrun error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be highly appreciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Apr 2018 11:30:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/UART0-different-behaviour-in-debug-mode/m-p/753973#M45951</guid>
      <dc:creator>faisalaslam</dc:creator>
      <dc:date>2018-04-20T11:30:57Z</dc:date>
    </item>
    <item>
      <title>Re: UART0 different behaviour in debug mode</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/UART0-different-behaviour-in-debug-mode/m-p/753974#M45952</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you let us know what's the UART TX/RX method, Polling or Interrupt?&lt;/P&gt;&lt;P&gt;If the KE02 chip with another modules working, which could cause UART receiver overrun flag was set.&lt;/P&gt;&lt;P&gt;What's the UART baud rate?&lt;/P&gt;&lt;P&gt;Could you provide the test code?&lt;/P&gt;&lt;P&gt;We could do a similar test on site.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Mike&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 May 2018 08:09:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/UART0-different-behaviour-in-debug-mode/m-p/753974#M45952</guid>
      <dc:creator>Hui_Ma</dc:creator>
      <dc:date>2018-05-02T08:09:15Z</dc:date>
    </item>
  </channel>
</rss>

