jump application from task for freertos in mpc5748‘s bootloader

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

jump application from task for freertos in mpc5748‘s bootloader

Jump to solution
1,871 Views
baixiaolin
Contributor II

Hi all,

i am runing a bootloader base on freertos,but it can't jump to application when run from task.

i know arm architect can switch psp to msp and set CONTROL register, but how to deal with powerpc?

thank you!

 

@PetrS

0 Kudos
Reply
1 Solution
1,863 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

the best way is to jump to the application right after reset. The startup code should only check a condition if bootloader or application should be started and then jump there without further initialization.

If you jump to the application later in the code, it is a must to disable interrupts on all levels (MSR[EE], priorities, local enable bits in peripherals) and it's also highly recommended to put all used resources back to default reset state.

There's no PSP/MSP on the PowerPC. R1 register is used as a stack and it is supposed to be initialized by startup code. So, you do not need to care about the stack.

Regards,

Lukas

View solution in original post

0 Kudos
Reply
2 Replies
1,864 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

the best way is to jump to the application right after reset. The startup code should only check a condition if bootloader or application should be started and then jump there without further initialization.

If you jump to the application later in the code, it is a must to disable interrupts on all levels (MSR[EE], priorities, local enable bits in peripherals) and it's also highly recommended to put all used resources back to default reset state.

There's no PSP/MSP on the PowerPC. R1 register is used as a stack and it is supposed to be initialized by startup code. So, you do not need to care about the stack.

Regards,

Lukas

0 Kudos
Reply
1,803 Views
baixiaolin
Contributor II

thanks for you help,

I have solved the problem,i close freertos's tick timer and deinit all model,then jump is success!   If someone else has this problem,you can debug then inquire mscr and mscrr0,what addr triggered the error.

0 Kudos
Reply