MM9S1J638 bootloader is not jumping into Application

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MM9S1J638 bootloader is not jumping into Application

1,030 次查看
vivek_sri
Contributor II

Hi

I'm working on a bootloader project on MM9S1J638. I'm having an issue while jumping into application code.

I'm using below code to jump into the application code.

void Jump_Main_Application(void)
{
app_vector = *(unsigned long int *) (APPLICATION_RESET_VEC_ADD+1);
asm LD X,app_vector;
asm JMP (0,X);
}

APPLICATION_RESET_VEC_ADD is BOOTLOADER_START_ADD-4

I've checked, it holds the last 3 bytes of the s19 file. which is same as the start address of the application code(_Startup).

The problem is that when I directly jump into the application code. Then it dosen' t work.

But when I place a breakpoint anywhere inside the above function and then run the code. Then it works totally fine.

0 项奖励
回复
1 回复

991 次查看
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @vivek_sri,

Just to be sure, what do you mean it does not work?

The application does not work or the debug session gets terminated?

You can attach the debugger (without reset) once it is in the application code to halt it and check registers etc.

Also, the MCU must always do something, either it is running the application or it is stuck in a loop.

Can you implement this ISRs with while(1){} in them at least?

danielmartynek_0-1651571645197.png

 

Thank you,

 

Regards,

Daniel

0 项奖励
回复