AnsweredAssumed Answered

MK22FN512 flash security

Question asked by Martin Dušek on Mar 26, 2019
Latest reply on Apr 3, 2019 by Kerry Zhou

Hi,

I use NXP_Kinetis_Bootloader_2_0_0\targets\MK22F51212\kds\freedom_bootloader flash resident bootloader and my app on MK22FN512.

 

What is the correct Flash Configuration value (address 0x400 - 0x40F)  for me if I want:

 

mass erase enabled

backdoor disabled

nxp factory access denied

flash memory readback protection enabled (there is no way anybody can read my app's code using jtag, ezport, bootloader api or anything else)

ezport disabled

update application firmware using the bootloader

 

I tried to set it to:

 

.section .FlashConfig, "a"
.long 0xFFFFFFFF
.long 0xFFFFFFFF
.long 0xFFFFFFFF
.long 0xFFFFF908

 

This way KinetisFlashTool shows that the security state is "SECURED" and the update of my app is not possible:

 

Updating image......
Error: Update image failed(Command disallowed when security is enabled.).

 

Thanks

 

Martin

Outcomes