[AT-START-F403A Evaluation] VI. FreeRTOS system based on IAR security library (sLib) secondary development mode practice
[Copy link]
This post was last edited by uuxz99 on 2020-10-22 21:47
In the process of implementing the slib function in the previous evaluation, due to the IAR crash problem, a compromise method was used to implement the slib function. This evaluation is a problem-solving process, and the secondary development mode of slib is implemented, that is, first burn the security code and start slib through the ICP method, and then download the user code through the IDE.
After analysis, it was found that the crash was caused by overlapping flash areas. Therefore, the following security measures were re-planned:
1. One page of instructions, 0x0800E000-0x080027FF
2. One page of data, 0x0800E800-0x08003000
1. Safe Code Project
1.1 Adjust the project to separate the data files and code files]
1.2 Security code project changes the ICF file security zone address
1.3 Confirm address allocation through map file after compilation
1.4 After IDE downloads, compile and observe the results to confirm that the safe zone has been downloaded correctly
1.5 Burn security code through ICP and start slib
1.5.1 . Extract the security zone code after connecting to AT-Link
1.5.2 Generate secure burning code file
1.5.3 Download the extracted file just generated and start the slib function
1.5.4 Confirm the slib function startup status and read the security zone content
2. User code project
2.1 Continue to use the user project from the last evaluation and adjust the ICF file
2.2 Adjust the user code download address.
Option->Debugger->Download->Edit (Override default .board file)->Edit->Flash Loader Overview->Flash Loader Configuration
2.3 After compiling and downloading, the safe zone codes are all 0xFF
2.4 Running and debugging user code
Conclusion :
1. In the secondary development mode, users do not need to touch the slib code, they just need to call it. In other words, after the supplier develops the core code, it is burned into the chip security zone and starts the security mode, and then the chip is delivered to the user. For the user, it is just like using a library function.
2. Debugging and running results
|