hi.
I use S32k144 and want to activate the security for prevent illegal access to memory from debugger. I change the "startup_S32K142.s" file according to available examples in the forum.
__FlashConfig
DCD 0x12345622 ; 8 bytes backdoor comparison key
DCD 0x12345678 ;
DCD 0xFFFFFFFF ; 4 bytes program flash protection bytes
DCD 0xFFFF7FBF ; FDPROT:FEPROT:FOPT:FSEC
__FlashConfig_End
But when I use debugger the memory is accessible and when disconnect debugger from MCU and read the location 0x408 it returned 0xFFFF7DFE !! (also in debugger). Backdoor phrases are write well.
Solved! Go to Solution.
Since you are using IAR, have you add --enable_config_write? refer: Using IAR EWARM to program flash configuration field?
The problem has been solved, thank you! When downloading the program in the security zone, the general debugger will not download the security zone by default, and it is necessary to configure the corresponding Settings before modifying the security zone value, but this will have the risk of the chip being permanently locked, how to set the specific setting can ask the debugger technical support.
Hi JeorgeB,
S32k144 should modify the "startup_S32K144.s". Why you change the "startup_S32K142.s"?
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.
-------------------------------------------------------------------------------
It was a typing mistake.
I try that in S32K142 and there was the same problem.
Have you try to use S32DS with P&E Micro debugger?
Hi Robin,
I also encountered such a problem in the S32DS, the SREC is BF, and the BE is when viewing after burning. What is the solution.
If you are using Segger J-Link, please select (allow security) when configure Target Device Settings.
The debugger I use is ic5000, I do not know why this phenomenon occurs, any suggestions
No, I use IAR and debug tool is jlink.
Since you are using IAR, have you add --enable_config_write? refer: Using IAR EWARM to program flash configuration field?