IMX93 M33 Test

From ESS-WIKI
Jump to: navigation, search

Use IMX93 Cortex-M33 to execute hello_world. Use example SDK_2_14_0_MCIMX93-EVK

  • Unzip SDK_2_14_0_MCIMX93-EVK
  • Install GCC Arm embedded tool chain

        Step 1:Set GCC  a new system environment variable(gcc-arm-none-eabi-9-2019-q4-major.tar.bz2)

download:https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads/9-2019-q4-major

        Step 2:/usr/local/Create a new folder arm and copy the compressed package.

$ cd /usr/local/ 
$ sudo mkdir arm 
$ cd arm 
$ sudo cp ~/tools/gcc-arm-none-eabi-9-2019-q4-major-x86_64-linux.tar.bz2 ./

        Step 3:/usr/local/arm tar jxvf.

$ sudo tar -vxf gcc-arm-none-eabi-9-2019-q4-major-x86_64-linux.tar.bz2

        Step 4:After unzip, delete the zip package and leave the folder.

$ sudo rm gcc-arm-none-eabi-9-2019-q4-major.tar.bz2

        Step 5:Add environment variables.

$ export ARMGCC_DIR=/usr/local/arm/gcc-arm-none-eabi-9-2019-q4-major/bin
$ export PATH=$PATH:/usr/local/arm/gcc-arm-none-eabi-9-2019-q4-major/bin

        Step 6:Check the gcc version number verification.

$ arm-none-eabi-gcc -v

Imx93 m33 gcc version.png

M33 Compiler

  • Build an example application.
$ cd ~/SDK_2_14_0_MCIMX93-EVK/boards/mcimx93evk/demo_apps/hello_world/armgcc
$ ./build_debug.sh
-- TOOLCHAIN_DIR: /work/platforms/tmp/gcc-arm-none-eabi-9-2019-q4-major
-- BUILD_TYPE: debug
-- TOOLCHAIN_DIR: /work/platforms/tmp/gcc-arm-none-eabi-9-2019-q4-major
-- BUILD_TYPE: debug
-- The ASM compiler identification is GNU
-- Found assembler: /work/platforms/tmp/gcc-arm-none-eabi-8-2019-q3-update/
bin/arm-none-eabi-gcc
-- Configuring done
-- Generating done
-- Build files have been written to:
/work/platforms/tmp/nxp/SDK_2.12.0_MCIMX93_EVK/boards/mcimx93evk/demo_apps/
hello_world/armgcc/demo_apps/hello_world/armgcc
Scanning dependencies of target hello_world.elf
[ 6%] Building C object CMakeFiles/hello_world.elf.dir/work/platforms/
tmp/nxp/SDK_2.12.0_MCIMX93_EVK/boards/mcimx93evk/demo_apps/hello_world/
hello_world.c.obj
 < -- skipping lines -- >
[100%] Linking C executable debug/hello_world.elf
[100%] Built target hello_world.elf

M33 Flash binary

  • Download bin to SD card
$ cd ~/SDK_2_14_0_MCIMX93-EVK/boards/mcimx93evk/demo_apps/hello_world/armgcc/debug
$ ls 
hello_world.elf  sdk20-app.bin
  • Copy sdk20-app.bin to IMX93 BSP boot partition.

Imx93 m33 boot partition.png

  • Open all USB serial Port ex:COM30 - COM34

Imx93 m33 usb serial.png

  • Enter to U-Boot command line mode. You can then write the image and run it from TCM with the following commands:
$ fatload mmc 1:1 80000000 sdk20-app.bin 
$ cp.b 0x80000000 0x201e0000 0x10000 
$ bootaux 0x1ffe0000 0

Imx93 m33 command line mode.png