<?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 Re: MCUXpresso-Convert project from C to C++ in MCUXpresso General</title>
    <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924451#M2109</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;there are ways to change the 'nature' (this is what the language support is called in Eclipse lingo) of a project, but this is really an expert thing, and you have to know what you are doing.&lt;/P&gt;&lt;P&gt;What I recommend is that you create a new C++ project from the Wizard and add your stuff to it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps,&lt;/P&gt;&lt;P&gt;Erich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 22 Jun 2019 06:59:30 GMT</pubDate>
    <dc:creator>BlackNight</dc:creator>
    <dc:date>2019-06-22T06:59:30Z</dc:date>
    <item>
      <title>MCUXpresso-Convert project from C to C++</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924450#M2108</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;I want to convert my existing MCUXpresso C projects into C++.&lt;/P&gt;&lt;P&gt;mcuxpresso 10.3‌&lt;/P&gt;&lt;P&gt;Please help me with some example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Mayur Savaj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Jun 2019 06:19:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924450#M2108</guid>
      <dc:creator>mayursavaj</dc:creator>
      <dc:date>2019-06-14T06:19:00Z</dc:date>
    </item>
    <item>
      <title>Re: MCUXpresso-Convert project from C to C++</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924451#M2109</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;there are ways to change the 'nature' (this is what the language support is called in Eclipse lingo) of a project, but this is really an expert thing, and you have to know what you are doing.&lt;/P&gt;&lt;P&gt;What I recommend is that you create a new C++ project from the Wizard and add your stuff to it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps,&lt;/P&gt;&lt;P&gt;Erich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 22 Jun 2019 06:59:30 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924451#M2109</guid>
      <dc:creator>BlackNight</dc:creator>
      <dc:date>2019-06-22T06:59:30Z</dc:date>
    </item>
    <item>
      <title>Re: MCUXpresso-Convert project from C to C++</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924452#M2110</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Totally agree, that's an expert thing and I, personally, having the same question and would like to learn how to do that. The main goal in my case is to take an example project as a base one and then extend it with custom code but I really would like to use C++ language features and the example project is a C project. I don't plan to restructure the original project, I just want to add new abilities to it. The example I'm talking about is definitely not a simple one, it is a zigbee based example. So, if I have to create a separate C++ project I at least need instructions how to add a zigbee stack to the newly create project.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2020 18:14:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924452#M2110</guid>
      <dc:creator>kucheravy</dc:creator>
      <dc:date>2020-07-06T18:14:10Z</dc:date>
    </item>
    <item>
      <title>Re: MCUXpresso-Convert project from C to C++</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924453#M2111</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Let me see if I can come up with an example for MCUXpresso IDE, similar to what I did in &lt;A class="link-titled" href="https://mcuoneclipse.com/2012/10/04/processor-expert-gcc-c-and-kinetis-l-and-mqxlite/" title="https://mcuoneclipse.com/2012/10/04/processor-expert-gcc-c-and-kinetis-l-and-mqxlite/"&gt;Processor Expert, gcc C++ and Kinetis-L with MQXLite | MCU on Eclipse&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Erich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Jul 2020 10:25:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924453#M2111</guid>
      <dc:creator>ErichStyger</dc:creator>
      <dc:date>2020-07-07T10:25:33Z</dc:date>
    </item>
    <item>
      <title>Re: MCUXpresso-Convert project from C to C++</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924454#M2112</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi @&lt;SPAN class=""&gt;&lt;A _jive_internal="true" class="" data-content-finding="Community" data-userid="361526" data-username="kucheravy@gmail.com" href="https://community.nxp.com/people/kucheravy@gmail.com"&gt;kucheravy@gmail.com&lt;/A&gt;&lt;/SPAN&gt;,&lt;/P&gt;&lt;P&gt;have a read at &lt;A class="link-titled" href="https://mcuoneclipse.com/2020/07/11/from-c-to-c-converting-eclipse-c-projekts/" title="https://mcuoneclipse.com/2020/07/11/from-c-to-c-converting-eclipse-c-projekts/"&gt;From C to C++: Converting Eclipse C Projects | MCU on Eclipse&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps,&lt;/P&gt;&lt;P&gt;Erich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Jul 2020 16:02:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924454#M2112</guid>
      <dc:creator>ErichStyger</dc:creator>
      <dc:date>2020-07-11T16:02:49Z</dc:date>
    </item>
    <item>
      <title>Re: MCUXpresso-Convert project from C to C++</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924455#M2113</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Interesting but unfortunately following these instructions is not possible. Somewhere in the middle, at the topic of "C++ startup code" it says "&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;Locate the C startup code in the project:&amp;nbsp;&lt;SPAN&gt;The easiest approach is to rename it to a C++ file with .cpp extension: " and then it suggest to make certain changes to that file. In my case with KW41Z the C generated example project has&amp;nbsp;startup_MKW41Z4.S startup file. It is written in assembler. Impossible to make the suggested changes and that is one of the important things.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp;Meanwhile I run into other issues with C++ projects. I was experimenting a lot.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;&lt;SPAN&gt;1. If I simply create a C++ project and then try to use&amp;nbsp;InstallIRQHandler from fsl_common which is basically added to the project by default and I even cannot untick it, it fails with linker errors like those:&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp;undefined reference to `__RAM_VECTOR_TABLE_SIZE_BYTES'&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;&lt;SPAN&gt;I learned that those symbols (like&amp;nbsp;&lt;SPAN style="background-color: #ffffff;"&gt;__RAM_VECTOR_TABLE_SIZE_BYTES) are supposed to be declared in the linker script file but by default C++ sets automatic linker script managing and as a result the symbols are missing and there is no example how to add what is necessary for the automatically added source code to the linker script. Apparently a custom linker script is generated with C projects and everything compiles in that case.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;&lt;SPAN style="background-color: #ffffff; "&gt;2. It looks like I run into another situation with the wrong order of linking obj files. I have a bunch of "undefined reference to" for the symbols which definitely exist in other obj files. I checked the methods signatures. Everything looks fine so I tend to believe the problem is the wrong linking order and I don't know how to resolve that. I hope this issue might automatically resolve if I resolve point 1 but I don't know how to do that.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #373737; background-color: #ffffff; font-weight: 300;"&gt;&lt;SPAN style="background-color: #ffffff; "&gt;&amp;nbsp; &amp;nbsp;All that is besides I still don't know how to port C to C++ and trying other approaches such as generating a basic C++ and then copy everything from C. That is much more tedious and does not work yet anyway.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Jul 2020 17:52:16 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/MCUXpresso-Convert-project-from-C-to-C/m-p/924455#M2113</guid>
      <dc:creator>kucheravy</dc:creator>
      <dc:date>2020-07-11T17:52:16Z</dc:date>
    </item>
  </channel>
</rss>

