Erase FLASH,S32K144 Reset,why?

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

Erase FLASH,S32K144 Reset,why?

6,174 Views
eautopower
Contributor IV

hello

boot memory configure:

pastedImage_1.png

APP memory configure:

pastedImage_2.png

erase code:

pastedImage_3.png

if code run here,the S32K144 reset:

pastedImage_4.png

pastedImage_5.png

9 Replies

3,774 Views
jinshuaixu
Contributor V

Hi,friend

     Did you have close interrupt? if you operate FLASH, you must close interrupt .

/* Erase the two PFlash sector */
address =ccp_save_address;
size = FEATURE_FLS_PF_BLOCK_SECTOR_SIZE*2;
ret = FLASH_DRV_EraseSector(&flashSSDConfig, address, size);
EnableInterrupts
if (ret != STATUS_SUCCESS)
{
while(1);
}

3,775 Views
tuozhou
Contributor II

hi,

   I'm having a similar problem,when I use the EEE partition,I jump to the Reset_Handler ,and I disable interrupt by use "cpsid i".

0 Kudos
Reply

3,775 Views
tuozhou
Contributor II

I see the RCM->SRS and I found Core lock up occurs when jump to the Reset_Handler.

3,775 Views
eautopower
Contributor IV

Hi jinshuai:

 yes,you are right,thank you!

another problem:

do you know the jump to APP code ?I don't how to jump,if you know send me mail: xiexingying@eautopower.com ,thank you very much!

0 Kudos
Reply

3,775 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

take a look at:

https://community.nxp.com/message/907130 

Regards,

Lukas

0 Kudos
Reply

3,775 Views
eautopower
Contributor IV

hi:

like this?

pastedImage_1.png

0 Kudos
Reply

3,775 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

If 0x8004 is address of reset vector then yes.

Regards,

Lukas

0 Kudos
Reply

3,775 Views
eautopower
Contributor IV

hi:

pastedImage_1.png

pastedImage_2.png

is right?

0 Kudos
Reply

3,774 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

have you disabled interrupts before jumping to user app? It is also good idea to reconfigure the device to default reset state. Or the user app must be aware that not everything is in default reset state.

If you step the asm code, are you able to get to start up code of user app? Where does it crash?

Regards,

Lukas

0 Kudos
Reply