How to get soft restart and hard restart

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

How to get soft restart and hard restart

1,373 次查看
1009427882
Contributor III

Hi,

I want to distinguish between soft and hard restarts, and I plan to use a piece of RAM that is not initialized by soft restarts to mark soft restarts. Is there such an example? Or how to make a soft restart of a RAM area without initialization?

0 项奖励
回复
3 回复数

1,279 次查看
davidtosenovjan
NXP TechSupport
NXP TechSupport

Hi, could you specify used device?

0 项奖励
回复

1,279 次查看
1009427882
Contributor III

Hi,I use MPC5748G chip.Is there any example for reference?

0 项奖励
回复

1,279 次查看
davidtosenovjan
NXP TechSupport
NXP TechSupport

You can use the MC_ME module to enter the RESET mode (SW functional reset):

 

/* software functional reset */   

ME.MCTL.R = 0x00005AF0;

ME.MCTL.R = 0x0000A50F;

 

or for SW destructive reset

ME.MCTL.R = 0xF0005AF0;

ME.MCTL.R = 0xF000A50F;

After functional reset SRAM content is preserved. You need to add to the initialization code checking of RGM module statuses to distinguish whether reset cause was destructive/functional reset and based on that perform or omit SRAM initialization.

0 项奖励
回复