<?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: How to jump to APP code from BOOT. in S32K</title>
    <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578763#M19890</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/194763"&gt;@zp001&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;First of all, EPSR means&amp;nbsp;Execution Program Status Register, EPSR. Before getting to this might help you&amp;nbsp;&amp;nbsp;&lt;A title="Special Register" href="https://developer.arm.com/documentation/ddi0419/c/System-Level-Architecture/System-Level-Programmers--Model/Registers/The-special-purpose-program-status-registers--xPSR?lang=en" target="_self"&gt;https://developer.arm.com/documentation/ddi0419/c/System-Level-Architecture/System-Level-Programmers--Model/Registers/The-special-purpose-program-status-registers--xPSR?lang=en.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;This kind of multi-project in a single MCU design requires a deinitialization process on every jump. Also vector table reallocation and PS &amp;amp; SP. Also, try to jump to&amp;nbsp;&lt;SPAN&gt;0x00501000 instated&amp;nbsp;0x00501004.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Sat, 07 Jan 2023 05:16:04 GMT</pubDate>
    <dc:creator>KalaimaniArumugamdev</dc:creator>
    <dc:date>2023-01-07T05:16:04Z</dc:date>
    <item>
      <title>How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1577933#M19837</link>
      <description>&lt;P&gt;Hello NXP team,&lt;/P&gt;&lt;P&gt;I'm developing bootloader on S32K344 platform.There was a hardfult issue when I tried to jump to APP from BOOTLOADER,&amp;nbsp;&lt;/P&gt;&lt;P&gt;here is my sample code:&lt;/P&gt;&lt;P&gt;typedef void (*AppAddr)(void);&lt;BR /&gt;int main(void)&lt;BR /&gt;{&lt;BR /&gt;/* Write your code here */&lt;BR /&gt;resetHandle = (AppAddr)(*(uint32_t *)0x00501420);&lt;BR /&gt;(resetHandle)();&lt;/P&gt;&lt;P&gt;.....&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;I get the reset handler address in APP map file, and the address of reset handler is&amp;nbsp;0x00501420, map file as below:&lt;/P&gt;&lt;P&gt;*(.startup)&lt;BR /&gt;*fill* 0x00501414 0xc&lt;BR /&gt;.startup 0x00501420 0x1c8 ./Project_Settings/Startup_Code/startup_cm7.o&lt;BR /&gt;0x00501420 _start&lt;BR /&gt;0x00501420 Reset_Handler&lt;BR /&gt;0x00501572 MCAL_LTB_TRACE_OFF&lt;BR /&gt;0x00501574 _end_of_eunit_test&lt;BR /&gt;0x005015e8 . = ALIGN (0x4)&lt;/P&gt;&lt;P&gt;I'd like to know why this happened and how debug under this situation.&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2023 11:08:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1577933#M19837</guid>
      <dc:creator>zp001</dc:creator>
      <dc:date>2023-01-05T11:08:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578433#M19870</link>
      <description>&lt;P&gt;Hi Zhend,&lt;/P&gt;
&lt;P&gt;this code will work if the provided address is an address of reset vector. In your case, it looks like you provide an address which is directly address of entry point.&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;P&gt;This is my vector table:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="lukaszadrapa_0-1672992842523.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/206307iB4A043803D2733EC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="lukaszadrapa_0-1672992842523.png" alt="lukaszadrapa_0-1672992842523.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Reset vector can be found at 0x00400004. So, entry point address is 0x004004C8.&lt;/P&gt;
&lt;P&gt;Using you code, it should be called like this:&lt;/P&gt;
&lt;P&gt;resetHandle = (AppAddr)(*(uint32_t *)0x00400004);&lt;BR /&gt;(resetHandle)();&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Lukas&lt;/P&gt;</description>
      <pubDate>Fri, 06 Jan 2023 08:16:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578433#M19870</guid>
      <dc:creator>lukaszadrapa</dc:creator>
      <dc:date>2023-01-06T08:16:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578755#M19888</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;SPAN&gt;Lukas,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Thank you for your help!&lt;/P&gt;&lt;P&gt;I don't understand how to get the address of reset handler in my S32K314 project.&lt;/P&gt;&lt;P&gt;Here is the key part of map file:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;.flash 0x00500000 0x3e61c
*(.boot_header)
.boot_header 0x00500000 0x2c ./Project_Settings/Startup_Code/startup_cm7.o
0x00501000 . = ALIGN (0x1000)
*fill* 0x0050002c 0xfd4
0x00501000 __text_start = .
0x00501000 __interrupts_rom_start = .
*(.intc_vector)
.intc_vector 0x00501000 0x408 ./Project_Settings/Startup_Code/Vector_Table.o
0x00501000 VTABLE
0x00501408 . = ALIGN (0x4)
0x00501408 __interrupts_rom_end = .
*(.core_loop)
.core_loop 0x00501408 0xc ./Project_Settings/Startup_Code/startup_cm7.o
0x00501408 _core_loop
0x00501414 . = ALIGN (0x4)
*(.startup)
*fill* 0x00501414 0xc
.startup 0x00501420 0x1c8 ./Project_Settings/Startup_Code/startup_cm7.o
0x00501420 _start
0x00501420 Reset_Handler
0x00501572 MCAL_LTB_TRACE_OFF
0x00501574 _end_of_eunit_test
0x005015e8 . = ALIGN (0x4)
...
...
...
 *(.mcal_text)
 .mcal_text     0x0051b094       0x14 ./Project_Settings/Startup_Code/exceptions.o
                0x0051b094                NMI_Handler
                0x0051b096                HardFault_Handler
                0x0051b098                MemManage_Handler
                0x0051b09a                BusFault_Handler
                0x0051b09c                UsageFault_Handler
                0x0051b0a0                DebugMon_Handler
                0x0051b0a6                undefined_handler
 .mcal_text     0x0051b0a8       0x52 ./Project_Settings/Startup_Code/nvic.o
                0x0051b0a8                NVIC_SetPriorityGrouping
                0x0051b0bc                NVIC_EnableIRQ
                0x0051b0d4                NVIC_DisableIRQ
                0x0051b0ec                NVIC_SetPriority&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;The corresponding&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;memory conten&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;is&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=""&gt;shown as below:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="zp001_0-1673060155203.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/206364i616FFBD74EB35348/image-size/medium?v=v2&amp;amp;px=400" role="button" title="zp001_0-1673060155203.png" alt="zp001_0-1673060155203.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;In my case, the&amp;nbsp;0x00501004 is physical address of reset vector, is that right?&lt;/P&gt;&lt;P&gt;But I tried to jump&amp;nbsp;0x00501004 and got failure again!&lt;/P&gt;&lt;P&gt;Did I miss any key point?&lt;/P&gt;&lt;P&gt;An error log printed in the console:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;UsageFault: An instruction executed with an invalid EPSR.T or EPSR.IT field. 
HardFault: A fault has been escalated to a hard fault. &lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;I'd like to know how to get the reset vector adrress .would you like to share any reference documents?&lt;/P&gt;</description>
      <pubDate>Sat, 07 Jan 2023 02:58:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578755#M19888</guid>
      <dc:creator>zp001</dc:creator>
      <dc:date>2023-01-07T02:58:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578763#M19890</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/194763"&gt;@zp001&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;First of all, EPSR means&amp;nbsp;Execution Program Status Register, EPSR. Before getting to this might help you&amp;nbsp;&amp;nbsp;&lt;A title="Special Register" href="https://developer.arm.com/documentation/ddi0419/c/System-Level-Architecture/System-Level-Programmers--Model/Registers/The-special-purpose-program-status-registers--xPSR?lang=en" target="_self"&gt;https://developer.arm.com/documentation/ddi0419/c/System-Level-Architecture/System-Level-Programmers--Model/Registers/The-special-purpose-program-status-registers--xPSR?lang=en.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;This kind of multi-project in a single MCU design requires a deinitialization process on every jump. Also vector table reallocation and PS &amp;amp; SP. Also, try to jump to&amp;nbsp;&lt;SPAN&gt;0x00501000 instated&amp;nbsp;0x00501004.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Jan 2023 05:16:04 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578763#M19890</guid>
      <dc:creator>KalaimaniArumugamdev</dc:creator>
      <dc:date>2023-01-07T05:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578771#M19892</link>
      <description>&lt;P&gt;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/203123"&gt;@KalaimaniArumugamdev&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Thank you for your reply!&lt;/P&gt;&lt;P&gt;Finally, the code can be run normally by using 0x00501004 as entry of APP image.&lt;/P&gt;&lt;P&gt;Thank you all.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Jan 2023 07:43:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1578771#M19892</guid>
      <dc:creator>zp001</dc:creator>
      <dc:date>2023-01-07T07:43:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1739100#M27813</link>
      <description>&lt;P&gt;hi, I met a same problem. Could you tell me the detail to slove my problem&lt;/P&gt;</description>
      <pubDate>Fri, 13 Oct 2023 03:53:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1739100#M27813</guid>
      <dc:creator>bwp530</dc:creator>
      <dc:date>2023-10-13T03:53:42Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1773823#M29578</link>
      <description>&lt;P&gt;需要找到APP代码中断向量表的起始地址，app跳转入口地址就是这个+4&lt;/P&gt;</description>
      <pubDate>Wed, 13 Dec 2023 09:55:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1773823#M29578</guid>
      <dc:creator>xuliwei</dc:creator>
      <dc:date>2023-12-13T09:55:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1851365#M34480</link>
      <description>&lt;P&gt;Hi, I am using the project "S32K344_Can_bootloader_RTD200" in the microprocessor S32K344. I want to download an application with the program of bootloader. I have achieved the jump from program to application but I have different questions. 1. I want to use #define EN_DELAY_TIME but when I uncomment the command in the folder "public_in", the program has different errors. My target to use "Backdoor", that is to say, I want to check if the program has to enter to bootloader or not. I don´t know the process and the different functions that I have to use to achieve the target. I want to use the function "Boot_CheckReqBootloaderMode(void)" but when I debug the program, it never enters to the "if". Could you explain me the process and the steps to achieve the target. I add different functions that I think are important. 2. I don´t know if I have to modificate the parameters of "static tJumpAppDelayTimeInfo gs_stJumpAPPDelayTimeInfo = {FALSE, 0u};". I have to change this structure ? You can see all structure in one of the next pictures. I need the reply as soon as possible since I have to send a project very soon.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JonAnder_Amante_0-1713768865077.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/274939i781B4A8B4F9C79CB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JonAnder_Amante_0-1713768865077.png" alt="JonAnder_Amante_0-1713768865077.png" /&gt;&lt;/span&gt;&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;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JonAnder_Amante_1-1713768865113.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/274938i85D466D8CAF57F8A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JonAnder_Amante_1-1713768865113.png" alt="JonAnder_Amante_1-1713768865113.png" /&gt;&lt;/span&gt;&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;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JonAnder_Amante_2-1713768865165.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/274940iC35E5955266F317B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JonAnder_Amante_2-1713768865165.png" alt="JonAnder_Amante_2-1713768865165.png" /&gt;&lt;/span&gt;&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;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JonAnder_Amante_3-1713768865168.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/274941i8AB1A44DA751BBDC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JonAnder_Amante_3-1713768865168.png" alt="JonAnder_Amante_3-1713768865168.png" /&gt;&lt;/span&gt;&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;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JonAnder_Amante_4-1713768865167.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/274942iCD7675CAB688F3F8/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JonAnder_Amante_4-1713768865167.png" alt="JonAnder_Amante_4-1713768865167.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for all,&lt;/P&gt;</description>
      <pubDate>Mon, 22 Apr 2024 06:54:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1851365#M34480</guid>
      <dc:creator>JonAnder_Amante</dc:creator>
      <dc:date>2024-04-22T06:54:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to jump to APP code from BOOT.</title>
      <link>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1930940#M39403</link>
      <description>&lt;P&gt;你好，请问你是怎么改的呀，我遇到了个一摸一样的问题&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.nxp.com/t5/S32K/Hard-Fault-trap-happens-when-Boot-jump-into-Bsw/td-p/1929837" target="_blank"&gt;Hard Fault trap happens when Boot jump into Bsw - NXP Community&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Aug 2024 08:20:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/How-to-jump-to-APP-code-from-BOOT/m-p/1930940#M39403</guid>
      <dc:creator>yinqiu</dc:creator>
      <dc:date>2024-08-13T08:20:09Z</dc:date>
    </item>
  </channel>
</rss>

