Regarding the use of FS32K146HAT0MLLR, I encountered the following issues:
During usage, I need to simultaneously enable CSEc and Flash Security (FSEC=0xBF). However, even after enabling mass erase, I am unable to perform operations.
1.If I want to re-enable the debug port, how should I proceed?
2.If I need to recover the partition, what steps should I follow?
Could you provide detailed instructions to achieve these operations?
I would greatly appreciate your prompt reply.
Hi @xyzhang
This was discussed here many times. For example here:
If CSEc is enabled, mass erase is blocked.
To make the debugging/development/tests easier, my recommendation is to implement following functionality to your application: when some push button is pressed or when certain command is received via UART/CAN, either reprogram FSEC to unsecure state 0xFE or run CMD_DBG_CHAL+CMD_DBG_AUTH commands. Or do both operations. So, you will be able to recover and start over.
Or implement backdoor access, so you will be able to connect the debugger, at least:
But if nothing like this is implemented and the device is secured and CSEc is enabled - there's no way to recover.
Regards,
Lukas
1. If you read whole flash memory to a file by the Cyclone in both cases, is the flash content exactly the same?
2. Is content of FCFG1 register in SIM module the same in both cases?
Yes, configuring of FSEC could make a difference. The questions is how Pemicro implemented this in their firmware. My colleague told me that he met something similar on S12 devices – it worked with debugger but not with Cyclone in standalone mode. And it was caused by different approach to security byte in flash. But notice that this is Pemicro’s proprietary firmware, so I recommend to check this with them directly:
https://www.pemicro.com/support/index.cfm
Have you implemented Backdoor Key Access to your software? Are you able to connect your debugger to this device? If yes, can you check the content of flash configuration field at 0x400?