<?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>Model-Based Design Toolbox (MBDT)のトピックRe: MPC5744P LinFlex UART is very slow &amp; possible fix</title>
    <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/MPC5744P-LinFlex-UART-is-very-slow-possible-fix/m-p/715326#M1368</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/markusransberger"&gt;markusransberger&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I must thank you again for your interest!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I opened&amp;nbsp;a feature request internally (&lt;A href="http://sw-jira.freescale.net/browse/AST-873"&gt;AST-873&lt;/A&gt;) and we will take a look and fix this in our next release for MPC5774P.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Razvan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 31 Oct 2017 16:51:32 GMT</pubDate>
    <dc:creator>constantinrazva</dc:creator>
    <dc:date>2017-10-31T16:51:32Z</dc:date>
    <item>
      <title>MPC5744P LinFlex UART is very slow &amp; possible fix</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/MPC5744P-LinFlex-UART-is-very-slow-possible-fix/m-p/715325#M1367</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 just want to tell you that the LinFlex UART implementation is almost unusable slow. It takes around 250ms to transmit a hard-coded string of just 16 characters. That's 15.625ms per character. Can somebody please look into it for the next version?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I went ahead and implemented the code of one of your C examples and voilà it actually takes around 2.2ms now to transmit about 20 characters.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In linflexd_pnt_library.c I replaced the "void linflexd_pnt_TxMsg(...)" function with the following:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;void linflexd_pnt_TxMsg(uint8_t linflexd_unit, uint8_t *u8TxData,&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;uint32_t u32Size) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;uint8_t&amp;nbsp;&amp;nbsp; &amp;nbsp;j = 0; // Dummy variable&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;for( j=0; j &amp;lt; u32Size; j++ ) &lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Loop for character string &amp;nbsp;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;LINFlexD[linflexd_unit]-&amp;gt;BDRL.B.DATA0 = *(u8TxData+j);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;//write character to transmit buffer&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;while (1 != LINFlexD[linflexd_unit]-&amp;gt;UARTSR.B.DTFTFF) {}&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// Wait for data transmission completed flag&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;LINFlexD[linflexd_unit]-&amp;gt;UARTSR.R = 0x0002;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// clear the DTF flag and not the other flags&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Since in the old function there is this code in it:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;// &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;u32Cnt = 100000;&lt;BR /&gt;//&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; while ((UART_TX_FLAG == 0) &amp;amp;&amp;amp; (u32Cnt &amp;gt; 0))/* Wait for Data to get transmitted */&lt;BR /&gt;//&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; { u32Cnt--; }&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;And this takes ages to complete.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also in the "mbdtargetmainlibpnt.tlc" file, in the "void linflex_init_fnc(void)" function I commented out all of the timeout counter and output compare writes to the registers, but I did not test if this is necessary. (Now it's almost identical to the UART C example.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Markus Ransberger&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Oct 2017 16:08:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/MPC5744P-LinFlex-UART-is-very-slow-possible-fix/m-p/715325#M1367</guid>
      <dc:creator>markusransberge</dc:creator>
      <dc:date>2017-10-23T16:08:19Z</dc:date>
    </item>
    <item>
      <title>Re: MPC5744P LinFlex UART is very slow &amp; possible fix</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/MPC5744P-LinFlex-UART-is-very-slow-possible-fix/m-p/715326#M1368</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/markusransberger"&gt;markusransberger&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I must thank you again for your interest!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I opened&amp;nbsp;a feature request internally (&lt;A href="http://sw-jira.freescale.net/browse/AST-873"&gt;AST-873&lt;/A&gt;) and we will take a look and fix this in our next release for MPC5774P.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Razvan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 31 Oct 2017 16:51:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/MPC5744P-LinFlex-UART-is-very-slow-possible-fix/m-p/715326#M1368</guid>
      <dc:creator>constantinrazva</dc:creator>
      <dc:date>2017-10-31T16:51:32Z</dc:date>
    </item>
  </channel>
</rss>

