CodeWarrior 10.6 debug bootloader(mpc5604)

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

CodeWarrior 10.6 debug bootloader(mpc5604)

514 Views
ahjg_xu
Contributor II

MPC5604 debug bootloader problem:

Before I jump to App, I should to do :

=== If you use the mcuxpressIde Debug boot jump app, use the following steps:======

1、should set SP pointer and PC pointer.

If the App start address is 0xb000, the SP pointer initial address is 0xb000 and PC pointer initial address is 0xb004.

2、 refer to below code.

appEntry =(*(unsigned int*)0xb0004);

appStack = (*(unsigned int*)0xb0000);

static void (*farewellBootloader)(void) = 0;

farewellBootloader = (void (*)(void))appEntry ;

// Set the VTOR to the application vector table address.

SCB->VTOR = 0xb000; // Set stack pointers to the application stack pointer.

__set_MSP(appStack );

__set_PSP(appStack );

// Jump to the application.

farewellBootloader();

===but If you use the CodeWarrior Debug boot jump app,I don’t know how to do======

I think it is also necessary to set SP pointer 、PC pointer and vector.

But I can't find the corresponding operation function.

Please tell me how to operate it,

(I Use Codewarrior 10.6 ,and MPC5604 cpu)

 

 

0 Kudos
Reply
0 Replies