<?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 RT1170-EVK how enable PRINTF float ? Removing CR_INTEGER_PRINTF did not help? in i.MX RT Crossover MCUs</title>
    <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1431426#M18849</link>
    <description>&lt;P&gt;PRINTF does not print float numbers when %f is used?&lt;/P&gt;&lt;P&gt;I am using PRTINT on RTK1170-EVK M4 core.&lt;/P&gt;&lt;P&gt;Removing CR_INTEGER_PRINTF did not help?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;evkmimxrt1170_hello_world_cm4&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;    (void)PRINTF("\r\n[m4]Print float=%f prints nothing?\r\n\n", 
3.14);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Example Output:&lt;/P&gt;&lt;P&gt;[m4]Print float=&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 21 Mar 2022 17:46:59 GMT</pubDate>
    <dc:creator>EdOfTheMountain</dc:creator>
    <dc:date>2022-03-21T17:46:59Z</dc:date>
    <item>
      <title>RT1170-EVK how enable PRINTF float ? Removing CR_INTEGER_PRINTF did not help?</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1431426#M18849</link>
      <description>&lt;P&gt;PRINTF does not print float numbers when %f is used?&lt;/P&gt;&lt;P&gt;I am using PRTINT on RTK1170-EVK M4 core.&lt;/P&gt;&lt;P&gt;Removing CR_INTEGER_PRINTF did not help?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;evkmimxrt1170_hello_world_cm4&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;    (void)PRINTF("\r\n[m4]Print float=%f prints nothing?\r\n\n", 
3.14);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Example Output:&lt;/P&gt;&lt;P&gt;[m4]Print float=&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Mar 2022 17:46:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1431426#M18849</guid>
      <dc:creator>EdOfTheMountain</dc:creator>
      <dc:date>2022-03-21T17:46:59Z</dc:date>
    </item>
    <item>
      <title>Re: RT1170-EVK how enable PRINTF float ? Removing CR_INTEGER_PRINTF did not help?</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1431455#M18850</link>
      <description>&lt;P&gt;&lt;FONT face="courier new,courier"&gt;This solution works. Removing CR_INTEGER_PRINTF by itself did NOT help.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;In MCUXpresso, right-mouse click project, select Properties, C/C++ Build &amp;gt; Settings, then MCU C Compiler &amp;gt; Preprocessor&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;if SDK_DEBUGCONSOLE = 0 then PRINTF is directed to printf() in the C library.&amp;nbsp; &lt;/FONT&gt;&lt;FONT face="courier new,courier"&gt;Code size is larger, but printf will work for floats.&amp;nbsp;&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Add &lt;STRONG&gt;SDK_DEBUGCONSOLE_UART&lt;/STRONG&gt; to redirect printf output to UART.&lt;/FONT&gt;&lt;/P&gt;&lt;PRE&gt;&lt;FONT face="courier new,courier"&gt;SDK_DEBUGCONSOLE=0&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;SDK_DEBUGCONSOLE_UART&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;H5&gt;&lt;A href="https://blog.birost.com/a?ID=01750-a14047e5-edcc-4f82-9227-82c7c430e83c" target="_self"&gt;MCUXpresso Using of printf&lt;/A&gt;&lt;/H5&gt;</description>
      <pubDate>Mon, 21 Mar 2022 18:26:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1431455#M18850</guid>
      <dc:creator>EdOfTheMountain</dc:creator>
      <dc:date>2022-03-21T18:26:25Z</dc:date>
    </item>
    <item>
      <title>Re: RT1170-EVK how enable PRINTF float ? Removing CR_INTEGER_PRINTF did not help?</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1467191#M19865</link>
      <description>&lt;P&gt;I have similar problems however, when I followed the instructions that were given above, the PRINTF does not even output anything at all.&lt;/P&gt;&lt;P&gt;There is another preprocessor which is PRINTF_FLOAT_ENABLE=0. I changed that to 1 and keep the original settings.&lt;/P&gt;&lt;P&gt;In summary:&lt;/P&gt;&lt;P&gt;1. SDK_DEBUGCONSOLE=1&lt;/P&gt;&lt;P&gt;2. CR_INTEGER_PRINTF (didnt remove)&lt;/P&gt;&lt;P&gt;3. PRINTF_FLOAT_ENABLE=1 (changed from 0 to 1).&lt;/P&gt;&lt;P&gt;And it prints out the float. Anyway, I still need to confirm if that is correct or not.&lt;/P&gt;&lt;P&gt;However, I have a few questions regarding this.&lt;/P&gt;&lt;P&gt;1. Why didnt the SDK keep the preprocessor as 1 by default?&lt;/P&gt;&lt;P&gt;2. Why is the above proposed solution not working for my case?&lt;/P&gt;&lt;P&gt;3. What are those two preprocessors (CR_INTEGER_PRINTF) and (PRINTF_FLOAT_ENABLE=1) doing to be exact? Why do we need them in the first place?&lt;/P&gt;&lt;P&gt;4. Based on my understanding that SDK_DEBUGCONSOLE=1 means using some SDK debug print and not the C printf(), what are the difference between them? Why when I set it 0 and defined the UART preprocessor, I have nothing at all since it should be the standard C printf()?&amp;nbsp;&lt;/P&gt;&lt;P&gt;4. If I am using KEIL and the toolset could be different, do I still need to define all these preprocessor?&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Desmond&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 01 Jun 2022 05:26:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/RT1170-EVK-how-enable-PRINTF-float-Removing-CR-INTEGER-PRINTF/m-p/1467191#M19865</guid>
      <dc:creator>Desmond_lim</dc:creator>
      <dc:date>2022-06-01T05:26:13Z</dc:date>
    </item>
  </channel>
</rss>

