samples: tfm_integration: lpc55s69 support
Adds documentation on how to run TFM samples on LPCxpresso55S69 board. Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
This commit is contained in:
parent
7ff38a9b6d
commit
b8b31f9a76
|
@ -196,10 +196,10 @@ see the following message in the terminal:
|
|||
Hello World! lpcxpresso55s69_cpu0
|
||||
|
||||
Building and flashing secure/non-secure with Arm |reg| TrustZone |reg|
|
||||
---------------------------------------------------------------------
|
||||
----------------------------------------------------------------------
|
||||
The TF-M integration samples can be run using the ``lpcxpresso55s69_ns`` target.
|
||||
Next we need to manually flash the secure (`tfm_s.hex`)
|
||||
and non-secure (`zephyr.hex`) images wth a J-Link as follows:
|
||||
Next we need to manually flash the secure (``tfm_s.hex``)
|
||||
and non-secure (``zephyr.hex``) images wth a J-Link as follows:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
|
|
|
@ -7,19 +7,12 @@ set(QEMU_KERNEL_OPTION "-device;loader,file=${CMAKE_BINARY_DIR}/tfm_qemu.hex")
|
|||
|
||||
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
|
||||
|
||||
set(BL2 $ENV{BL2})
|
||||
if(NOT DEFINED BL2)
|
||||
#by default build with MCUboot
|
||||
set(BL2 True)
|
||||
endif()
|
||||
|
||||
# Add "tfm" as an external project via the TF-M module's cmake file
|
||||
trusted_firmware_build(BINARY_DIR ${CMAKE_BINARY_DIR}/tfm
|
||||
BOARD ${TFM_TARGET_PLATFORM}
|
||||
IPC
|
||||
CFGFILE "ConfigRegressionIPC"
|
||||
OUT_VENEERS_FILE VENEERS_FILE
|
||||
BL2 ${BL2}
|
||||
)
|
||||
|
||||
project(tfm_psa_level_1)
|
||||
|
|
|
@ -29,8 +29,7 @@ Building and Running
|
|||
********************
|
||||
|
||||
This project outputs startup status and info to the console. It can be built and
|
||||
executed on an MPS2+ configured for AN521 (dual-core ARM Cortex M33), or using
|
||||
the ``mps2_an521_nonsecure`` target with QEMU.
|
||||
executed on an ARM Cortex M33 target board or QEMU.
|
||||
|
||||
This sample will only build on a Linux or macOS development system
|
||||
(not Windows), and has been tested on the following setups:
|
||||
|
@ -126,6 +125,28 @@ and run it in qemu via the ``run`` command.
|
|||
cmake -DBOARD=mps2_an521_nonsecure ..
|
||||
make run
|
||||
|
||||
On LPCxpresso55S69:
|
||||
======================
|
||||
|
||||
Build Zephyr with a non-secure configuration:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ west build -p -b lpcxpresso55s69_ns samples/tfm_integration/psa_level_1/ --
|
||||
|
||||
Next we need to manually flash the secure (``tfm_s.hex``)
|
||||
and non-secure (``zephyr.hex``) images wth a J-Link as follows:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
JLinkExe -device lpc55s69 -if swd -speed 2000 -autoconnect 1
|
||||
J-Link>loadfile build/tfm/install/outputs/LPC55S69/tfm_s.hex
|
||||
J-Link>loadfile build/zephyr/zephyr.hex
|
||||
|
||||
NOTE: At present, the LPC55S69 doesn't include support for the MCUBoot bootloader.
|
||||
|
||||
We need to reset the board manually after flashing the image to run this code.
|
||||
|
||||
Sample Output
|
||||
=============
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ sample:
|
|||
tests:
|
||||
sample.tfm_ipc:
|
||||
tags: introduction
|
||||
platform_allow: mps2_an521_nonsecure
|
||||
platform_allow: mps2_an521_nonsecure lpcxpresso55s69_ns
|
||||
harness: console
|
||||
harness_config:
|
||||
type: multi_line
|
||||
|
|
|
@ -7,12 +7,6 @@ set(QEMU_KERNEL_OPTION "-device;loader,file=${CMAKE_BINARY_DIR}/tfm_qemu.hex")
|
|||
|
||||
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
|
||||
|
||||
set(BL2 $ENV{BL2})
|
||||
if(NOT DEFINED BL2)
|
||||
#by default build with MCUboot
|
||||
set(BL2 True)
|
||||
endif()
|
||||
|
||||
# Add "tfm" as an external project via the TF-M module's cmake file
|
||||
if(${TFM_TARGET_PLATFORM} STREQUAL "STM_NUCLEO_L552ZE_Q")
|
||||
trusted_firmware_build(BINARY_DIR ${CMAKE_BINARY_DIR}/tfm
|
||||
|
@ -20,7 +14,6 @@ if(${TFM_TARGET_PLATFORM} STREQUAL "STM_NUCLEO_L552ZE_Q")
|
|||
IPC
|
||||
CFGFILE "ConfigRegressionIPCTfmLevel2"
|
||||
OUT_VENEERS_FILE VENEERS_FILE
|
||||
BL2 ${BL2}
|
||||
)
|
||||
else()
|
||||
trusted_firmware_build(BINARY_DIR ${CMAKE_BINARY_DIR}/tfm
|
||||
|
@ -28,7 +21,6 @@ else()
|
|||
IPC
|
||||
CFGFILE "ConfigRegressionIPC"
|
||||
OUT_VENEERS_FILE VENEERS_FILE
|
||||
BL2 ${BL2}
|
||||
)
|
||||
endif()
|
||||
|
||||
|
|
|
@ -131,6 +131,27 @@ Reset the board.
|
|||
.. note::
|
||||
Note that ``arm-none-eabi-gcc`` should be available in the PATH variable and that ``STM32_Programmer_CLI`` is required to run ``regression.sh`` and ``TFM_UPDATE.sh`` (see https://www.st.com/en/development-tools/stm32cubeprog.html). If you are still having trouble running these scripts, check the Programming and Debugging section of the :ref:`nucleo_l552ze_q_board` documentation.
|
||||
|
||||
On LPCxpresso55S69:
|
||||
===================
|
||||
|
||||
Build Zephyr with a non-secure configuration:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ west build -p -b lpcxpresso55s69_ns samples/tfm_integration/tfm_ipc/ --
|
||||
|
||||
Next we need to manually flash the secure (``tfm_s.hex``)
|
||||
and non-secure (``zephyr.hex``) images wth a J-Link as follows:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
JLinkExe -device lpc55s69 -if swd -speed 2000 -autoconnect 1
|
||||
J-Link>loadfile build/tfm/install/outputs/LPC55S69/tfm_s.hex
|
||||
J-Link>loadfile build/zephyr/zephyr.hex
|
||||
|
||||
NOTE: At present, the LPC55S69 doesn't include support for the MCUBoot bootloader.
|
||||
|
||||
We need to reset the board manually after flashing the image to run this code.
|
||||
|
||||
Sample Output
|
||||
=============
|
||||
|
|
|
@ -5,7 +5,7 @@ sample:
|
|||
tests:
|
||||
sample.tfm_ipc:
|
||||
tags: introduction
|
||||
platform_allow: mps2_an521_nonsecure
|
||||
platform_allow: mps2_an521_nonsecure lpcxpresso55s69_ns
|
||||
harness: console
|
||||
harness_config:
|
||||
type: multi_line
|
||||
|
|
Loading…
Reference in a new issue