Hardware requirements
USB Type-C cable
MCIMX93AUTO-EVK board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
Note
Please run the application in Low Power boot mode (without Linux BSP). The IP module resource of the application is also used by Linux BSP. Or, run with Single Boot mode by changing Linux BSP to avoid resource conflict.
Prepare the Demo
Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW2 to power on the board.
Connect a USB Type-C cable between the host PC and the J26 USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the flash.bin to the target board. Reference ‘How to get flash.bin of TrustZone examples’ Reference ‘Getting Started with MCUXpresso SDK for MCIMX93AUTO-EVK.pdf’ to make and download flash.bin.
Press the reset button on your board.
How to get flash.bin of TrustZone examples:
Create a directory named ‘tz_bin’ in your work direcory.
Build {app}_s and copy sdk20-app.bin into ‘tz_bin’ then rename it as sdk20-app_s.bin.
Build {app}_ns and copy sdk20-app.bin into ‘tz_bin’ then rename it as sdk20-app_ns.bin.
Enter the ‘tz_bin’ directory and execute ‘dd’ command to combin the two files. dd if=sdk20-app_ns.bin of=sdk20-app_s.bin bs=1 count=
ls -l ./sdk20-app_ns.bin|awk '{print $5}'
seek=65536Rename sdk20-app_s.bin as m33_image.bin, and copy it into imx-mkimage
Build the low power boot flash.bin
Running the demo
The log below shows the output of the hello world demo in the terminal window:
Hello from secure world!
Entering normal world.
Welcome in normal world!
This is a text printed from normal world!
Comparing two string as a callback to normal world
String 1: Test1
String 2: Test2
Both strings are not equal!