<?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 How to relocate/execute a function to DDR. in MCUXpresso General</title>
    <link>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835432#M1075</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I based on the link:&amp;nbsp;&lt;A _jive_internal="true" class="link-titled" href="https://community.nxp.com/servlet/JiveServlet/download/104433-4-291307/Relocating Code and Data Using the KDS GCC Linker File for Kinetis.pdf" title="https://community.nxp.com/servlet/JiveServlet/download/104433-4-291307/Relocating+Code+and+Data+Using+the+KDS+GCC+Linker+File+for+Kinetis.pdf"&gt;https://community.nxp.com/servlet/JiveServlet/download/104433-4-291307/Relocating+Code+and+Data+Using+the+KDS+GCC+Linker…&lt;/A&gt;&amp;nbsp;and was able to relocate a function to the external DDR (0xa000_0000). I verified the relocated function was copied to the DDR and was able to single step to the function. However, as soon as I stepped to the first instruction "a4000000: push {r7, lr}", it led to the HardFault handler. Please help and let me know what am I missing.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I include the KDS example project in the attachment.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 27 Dec 2018 13:11:19 GMT</pubDate>
    <dc:creator>tandinh</dc:creator>
    <dc:date>2018-12-27T13:11:19Z</dc:date>
    <item>
      <title>How to relocate/execute a function to DDR.</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835432#M1075</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I based on the link:&amp;nbsp;&lt;A _jive_internal="true" class="link-titled" href="https://community.nxp.com/servlet/JiveServlet/download/104433-4-291307/Relocating Code and Data Using the KDS GCC Linker File for Kinetis.pdf" title="https://community.nxp.com/servlet/JiveServlet/download/104433-4-291307/Relocating+Code+and+Data+Using+the+KDS+GCC+Linker+File+for+Kinetis.pdf"&gt;https://community.nxp.com/servlet/JiveServlet/download/104433-4-291307/Relocating+Code+and+Data+Using+the+KDS+GCC+Linker…&lt;/A&gt;&amp;nbsp;and was able to relocate a function to the external DDR (0xa000_0000). I verified the relocated function was copied to the DDR and was able to single step to the function. However, as soon as I stepped to the first instruction "a4000000: push {r7, lr}", it led to the HardFault handler. Please help and let me know what am I missing.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I include the KDS example project in the attachment.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Dec 2018 13:11:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835432#M1075</guid>
      <dc:creator>tandinh</dc:creator>
      <dc:date>2018-12-27T13:11:19Z</dc:date>
    </item>
    <item>
      <title>Re: How to relocate/execute a function to DDR.</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835433#M1076</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &amp;nbsp;TAN DINH,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Make sure to initialize the external memory controller before trying to access the DDR memory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;BR /&gt;Carlos Mendoza&lt;BR /&gt;Technical Support Engineer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Jan 2019 14:59:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835433#M1076</guid>
      <dc:creator>Carlos_Mendoza</dc:creator>
      <dc:date>2019-01-14T14:59:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to relocate/execute a function to DDR.</title>
      <link>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835434#M1077</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Carlos,&lt;/P&gt;&lt;P&gt;Thanks for the reply. I did initialize the DDR before copying. I did find the solution for this. Instead of using physical address of DDR (0xA000_0000), I use the DDR_ALIAS address for code (0x1800_0000), then the issue goes away. I am able to step inside the function in DDR without any issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;-- Tan Dinh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Jan 2019 15:27:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-General/How-to-relocate-execute-a-function-to-DDR/m-p/835434#M1077</guid>
      <dc:creator>tandinh</dc:creator>
      <dc:date>2019-01-14T15:27:07Z</dc:date>
    </item>
  </channel>
</rss>

