<?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: Cannot resolve the error during compilation - &amp;quot;Error: Identifier &amp;quot;SIM&amp;quot; is undefined in &amp;quot;main.cpp&amp;quot;&amp;quot;</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941455#M54380</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello &lt;A ___default_attr="345651" _jive_internal="true" data-id="345651" data-objecttype="3" data-orig-content="Shobit Sharma" data-type="person" href="https://community.nxp.com/people/shobitsharma01@gmail.com" jivemacro="user"&gt;Shobit Sharma&lt;/A&gt;‌&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another solution is download the board sdk &lt;A href="https://mcuxpresso.nxp.com/en/welcome" title="https://mcuxpresso.nxp.com/en/welcome"&gt;Welcome | MCUXpresso SDK Builder&lt;/A&gt; .&lt;/P&gt;&lt;P&gt;You can replace your header for the included on the sdk folder. This allow you to call the SIM macro.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The sdk header is in the following direction: SDK_2.2.0_FRDM-KL25Z -&amp;gt; devices -&amp;gt; MKL25Z4&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let me know if this helps&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Omar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;---------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;Note:&lt;/P&gt;&lt;P&gt;- If this post answers your question, please click the "Mark Correct" button. Thank you!&lt;/P&gt;&lt;P&gt;----------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 02 Aug 2019 23:14:30 GMT</pubDate>
    <dc:creator>Omar_Anguiano</dc:creator>
    <dc:date>2019-08-02T23:14:30Z</dc:date>
    <item>
      <title>Cannot resolve the error during compilation - "Error: Identifier "SIM" is undefined in "main.cpp""</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941453#M54378</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I just started learning about ARM Cortex-M Microcontrollers and I am following this book -&amp;nbsp;&lt;STRONG&gt;"&lt;/STRONG&gt;&lt;STRONG&gt;&lt;SPAN style="text-decoration: underline; color: #222222; background-color: #ffffff; font-size: small;"&gt;Embedded Systems Fundamentals with Arm Cortex M Based Microcontrollers: A Practical Approach&lt;/SPAN&gt;&lt;SPAN style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&amp;nbsp;(ISBN-13: 978-1911531036) by&amp;nbsp;Alexander Dean".&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #222222; background-color: #ffffff; font-size: small;"&gt;I tried to compile the code given in the book to flash different colors on onboard RGB LED (file attached with name&amp;nbsp;&lt;EM&gt;&lt;STRONG&gt;Main.cpp&lt;/STRONG&gt;&lt;/EM&gt; and also the header file I used&amp;nbsp;&lt;EM&gt;&lt;STRONG&gt;MKL25Z4.h&lt;/STRONG&gt;&lt;/EM&gt;). I tried to create a .bin file using online Mbed IDE (&lt;A href="http://ide.mbed.com"&gt;ide.mbed.com&lt;/A&gt;) but I am getting the following error - "&lt;STRONG&gt;Error: Identifier "SIM" is undefined in "main.cpp", Line: 12, Col: 4&lt;/STRONG&gt;" and I am not able to figure out why.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Aug 2019 17:06:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941453#M54378</guid>
      <dc:creator>shobitsharma01</dc:creator>
      <dc:date>2019-08-02T17:06:47Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot resolve the error during compilation - "Error: Identifier "SIM" is undefined in "main.cpp""</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941454#M54379</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You say, "I am not able to figure out why," but I think that you have - you even stated the reason yourself. SIM is not defined.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A quick look into the header file, reveals this is true: the "SIM" macro is never defined, anywhere.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You try to access the SCGC5 field of SIM. Since SIM isn't defined anywhere, lets look for SCGC5. A search of the header, reveals that SCGC5 is a field of the SIM_MemMap struct. Seems promising. So we keep digging.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now we look for a macro or variable defined as a SIM_MemMap, or a pointer to one. Next, we find that this macro exists:&lt;/P&gt;&lt;P&gt;/* SIM - Peripheral instance base addresses */&lt;BR /&gt;/** Peripheral SIM base pointer */&lt;BR /&gt;#define SIM_BASE_PTR ((SIM_MemMapPtr)0x40047000u)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ta-dah! We have found the missing macro. Substituting "SIM_BASE_PTR" for "SIM&lt;SPAN&gt;", seems like a reasonable place to start.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Aug 2019 20:35:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941454#M54379</guid>
      <dc:creator>benjamin_tait</dc:creator>
      <dc:date>2019-08-02T20:35:50Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot resolve the error during compilation - "Error: Identifier "SIM" is undefined in "main.cpp""</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941455#M54380</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello &lt;A ___default_attr="345651" _jive_internal="true" data-id="345651" data-objecttype="3" data-orig-content="Shobit Sharma" data-type="person" href="https://community.nxp.com/people/shobitsharma01@gmail.com" jivemacro="user"&gt;Shobit Sharma&lt;/A&gt;‌&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another solution is download the board sdk &lt;A href="https://mcuxpresso.nxp.com/en/welcome" title="https://mcuxpresso.nxp.com/en/welcome"&gt;Welcome | MCUXpresso SDK Builder&lt;/A&gt; .&lt;/P&gt;&lt;P&gt;You can replace your header for the included on the sdk folder. This allow you to call the SIM macro.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The sdk header is in the following direction: SDK_2.2.0_FRDM-KL25Z -&amp;gt; devices -&amp;gt; MKL25Z4&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let me know if this helps&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Omar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;---------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;Note:&lt;/P&gt;&lt;P&gt;- If this post answers your question, please click the "Mark Correct" button. Thank you!&lt;/P&gt;&lt;P&gt;----------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Aug 2019 23:14:30 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941455#M54380</guid>
      <dc:creator>Omar_Anguiano</dc:creator>
      <dc:date>2019-08-02T23:14:30Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot resolve the error during compilation - "Error: Identifier "SIM" is undefined in "main.cpp""</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941456#M54381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank You&amp;nbsp;&lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/benjamin.tait@perkinelmer.com"&gt;benjamin.tait@perkinelmer.com&lt;/A&gt;‌ &amp;amp; &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/nxf54944"&gt;nxf54944&lt;/A&gt;‌ for your replies. I added&amp;nbsp;&lt;EM&gt;&lt;STRONG&gt;_BASE_PTR&amp;nbsp;&lt;/STRONG&gt;&lt;/EM&gt; to SIM, PORTB, PTB etc in the code and everything works. I will also try the SDK builder.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank You for your quick replies :smileyhappy:&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Aug 2019 04:12:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Cannot-resolve-the-error-during-compilation-quot-Error/m-p/941456#M54381</guid>
      <dc:creator>shobitsharma01</dc:creator>
      <dc:date>2019-08-03T04:12:37Z</dc:date>
    </item>
  </channel>
</rss>

