Flash protection S32k144

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

Flash protection S32k144

跳至解决方案
3,035 次查看
lohrsistemas
Contributor IV

Hi,

How do I program the options bytes to protect the flash reading?

Thanks.

1 解答
2,253 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

In this case, change the FSEC byte. Default value is 0xFE which means the device is not secured (you can access everything via JTAG). Last two bits say if the device is secured or not:

pastedImage_1.png

Change the value from 0xFFFF7FFE to 0xFFFF7FFC or 0xFFFF7FFD or 0xFFFF7FFF and the device will be secured. You can enable backdoor key access if needed.

Regards,

Lukas

在原帖中查看解决方案

4 回复数
2,253 次查看
lohrsistemas
Contributor IV

Thank you Lukas,

I really appreciate your prompt response and help.

Regards.

0 项奖励
回复
2,253 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

if you use S32 Design Studio, open the startup_S32K144.S file and search for this section:

pastedImage_3.png 

Just modify the words as you need.

pastedImage_2.png

Regards,

Lukas

0 项奖励
回复
2,253 次查看
lohrsistemas
Contributor IV

Hi Lukas, thanks for your feedback.

I'm using IAR plugin, so, my startup_S32K144.S is a little diferent.

pastedImage_1.png

However, I need to protect the flash against reading, but I have to program and delete it normally via JTAG. My code is confidential, so, customers cant read.

To do this, how should I set the bits described in the print screen?

Thanks.

0 项奖励
回复
2,254 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

In this case, change the FSEC byte. Default value is 0xFE which means the device is not secured (you can access everything via JTAG). Last two bits say if the device is secured or not:

pastedImage_1.png

Change the value from 0xFFFF7FFE to 0xFFFF7FFC or 0xFFFF7FFD or 0xFFFF7FFF and the device will be secured. You can enable backdoor key access if needed.

Regards,

Lukas