FLASH security configuration

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

FLASH security configuration

1,391 Views
Sourdev
Contributor II

Hi,

I am using S9KEAZN64AMLC MCU (Custom Board). I want to secure the FLASH After Flashing.

and again when I got the request over  LIN  or any other external request then I had to Unsecure,

Is there any way to do that? 

I went through the start-up code. If we change the value from FE to FD is flash will secure?

Sourdev_0-1689135932603.png

Can we do that if I want to change this configuration in run time?

I tried the following 

Sourdev_1-1689136253195.png

 

Sourdev_2-1689136286821.png

 

When any request comes from an external environment I am calling this function to unlock the FLASH but when control comes here it is going to default to ISR. Is it the right way to do that? 

 

If not how we can lock and unlock FLASH in RUN time?

And if FLASH is locked and unable to unlock then how we can do MASS Erase? (NOTE: I am using S32DS IDE  and PE Micro Multilink Universal ) 

 

Tags (1)
0 Kudos
Reply
1 Reply

1,357 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi

Please read 18.3.6 Protection of KEA64RM. If you change the value of Flash Configuration from FE to FD, the flash will secure. 0x40E is the address of Flash security byte. FTMRH_FSEC[SEC]=01 mean Secured. Refer to 18.4.2 Flash Security Register (FTMRH_FSEC).18.3.6 Protection KEA64RM.png

Recommended you refer to 18.3.7.1 Unsecuring the MCU using backdoor key access after you got the request over LIN or any other external request.


Best Regards,
Robin
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos
Reply