<?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>i.MX RT Crossover MCUs中的主题 Re: Unable to debug application with offset</title>
    <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1456940#M19527</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/189239"&gt;@bp1979&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;Which APP you want to debug now?&lt;/P&gt;
&lt;P&gt;&amp;nbsp; Talk about my experience with the secondary bootloader+application debug.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; As you know, the application debug have the offset, and the code running normally determined by the boot entry point, and that is normally from ROM BOOT+secondary boot+ app.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; So, if I need to debug the application, I will download the secondary bootloader which can jump to the application at first, then the application will works.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; Another way, test the application without the offset at first, after the code function totally works, then I do the offset, and download to the related offset area, test the function directly when + bootloader.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; So, to your situation, I suggest you can try to test the application without offset and debug it, it will make things easy.&lt;/P&gt;
&lt;P&gt;Best Regrads,&lt;/P&gt;
&lt;P&gt;Kerry&lt;/P&gt;</description>
    <pubDate>Thu, 12 May 2022 03:57:43 GMT</pubDate>
    <dc:creator>kerryzhou</dc:creator>
    <dc:date>2022-05-12T03:57:43Z</dc:date>
    <item>
      <title>Unable to debug application with offset</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1452184#M19422</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;using imx rt 1024, for my position independent code experiment I am trying to debug my "offsetted" application, but gdb isn't loading the symbols.&lt;/P&gt;&lt;P&gt;What am I doing wrong?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="bp1979_0-1651569283441.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/178641i73E29DD66C5C1DD5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="bp1979_0-1651569283441.png" alt="bp1979_0-1651569283441.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;For background:&lt;/P&gt;&lt;P&gt;- my bootloader sits at 0x60000000&lt;/P&gt;&lt;P&gt;- app1 (not uploaded) normally sits at 0x60020000&lt;/P&gt;&lt;P&gt;- app2 is uploaded with above offsets of 0x10000&lt;/P&gt;&lt;P&gt;When I debug the app with above configuration, when I press suspend debugger I can analyze the memory. I can see that my app is properly uploaded to 0x6003000. But the debugger (gdb) is not able to locate the symbols&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="bp1979_1-1651569461045.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/178642iC7A2D02AC885F6E3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="bp1979_1-1651569461045.png" alt="bp1979_1-1651569461045.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(memory shows my app is in memory on desired offset location)&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="bp1979_2-1651569510969.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/178643i048D76E33FD43D56/image-size/medium?v=v2&amp;amp;px=400" role="button" title="bp1979_2-1651569510969.png" alt="bp1979_2-1651569510969.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;PS: vector table and .got are both in sram. in my startup code I properly patch the ISR vector addresses, so that's not the problem. When I put a breakpoint in the first line of my ResetHandler, it doesn't hit. When I pause my application once started, it can't find symbols.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 09:20:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1452184#M19422</guid>
      <dc:creator>bp1979</dc:creator>
      <dc:date>2022-05-03T09:20:21Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to debug application with offset</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1453619#M19454</link>
      <description>&lt;P&gt;Dear nxp,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;any solution for this? using an incredible cumbersome way to debug my position independent app this way.&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2022 14:22:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1453619#M19454</guid>
      <dc:creator>bp1979</dc:creator>
      <dc:date>2022-05-05T14:22:43Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to debug application with offset</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1456940#M19527</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/189239"&gt;@bp1979&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;Which APP you want to debug now?&lt;/P&gt;
&lt;P&gt;&amp;nbsp; Talk about my experience with the secondary bootloader+application debug.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; As you know, the application debug have the offset, and the code running normally determined by the boot entry point, and that is normally from ROM BOOT+secondary boot+ app.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; So, if I need to debug the application, I will download the secondary bootloader which can jump to the application at first, then the application will works.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; Another way, test the application without the offset at first, after the code function totally works, then I do the offset, and download to the related offset area, test the function directly when + bootloader.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; So, to your situation, I suggest you can try to test the application without offset and debug it, it will make things easy.&lt;/P&gt;
&lt;P&gt;Best Regrads,&lt;/P&gt;
&lt;P&gt;Kerry&lt;/P&gt;</description>
      <pubDate>Thu, 12 May 2022 03:57:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1456940#M19527</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2022-05-12T03:57:43Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to debug application with offset</title>
      <link>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1458852#M19580</link>
      <description>&lt;P&gt;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/60336"&gt;@kerryzhou&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Managed to get it working after all. Using gdb command `add-symbol-file &amp;lt;path-to-elf&amp;gt; &amp;lt;address-to-text-section&amp;gt; just before I jump from my bootloader to the relocated app fixed it.&lt;/P&gt;&lt;P&gt;Well, to be fair, I didn't test it in MCUxresso, I migrated my projects to VScode instead (compiling with CMake). But I am sure it works all the same in MCUxpresso&lt;/P&gt;</description>
      <pubDate>Mon, 16 May 2022 21:49:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-RT-Crossover-MCUs/Unable-to-debug-application-with-offset/m-p/1458852#M19580</guid>
      <dc:creator>bp1979</dc:creator>
      <dc:date>2022-05-16T21:49:27Z</dc:date>
    </item>
  </channel>
</rss>

