Arm Community
Arm Community
  • Site
  • User
  • Site
  • Search
  • User
Open Source Software and Platforms
Open Source Software and Platforms
Wiki MPS2+ SSE-200 TF-M Examples User Guide
  • Help
  • Jump...
  • Cancel
  • About this wiki
  • Supported platforms
  • Obtaining support
  • +Arm Reference Platforms deliverables
  • +A-class platforms
  • +M-class platforms
  • +R-class platforms
  • -FPGA prototyping boards
    • -MPS2(+) FPGA prototyping board
      • MPS2(+) M-class prototyping system
      • Keil Board Support Packs for MPS2(+)
      • -Keil pack for SSE-200 IoT System for MPS2+
        • -SSE-200 for MPS2+ Software Examples
          • MPS2+ SSE-200 TF-M Examples User Guide
          • MPS2+ SSE-200 Devices Example
          • MPS2+ SSE-200 Devices Secure/Non-secure Example
          • MPS2+ SSE-200 Secure/Non-secure Blinky Example
      • Running uCLinux on the Arm MPS2(+) platform
      • MPS2(+) Mbed OS automated testing
      • FPGA Prescale register address incorrect in MPS2(+) software header file
      • MPS2+ Firmware update for reboot.txt method
    • +MPS3 FPGA Prototyping System
  • +Open source software

MPS2+ SSE-200 TF-M Examples User Guide

Each of the examples consist of 4 projects. Two projects provide the secure and the non-secure images to be run on the board.  Two other projects provide secure services libraries (Audit Log, Secure Storage) utilised by the Secure image.

Build

In order to build or load a project it needs to be set as the active project in Keil.

To compile this example correctly the secure services needs to be compiled first as libraries, then the secure project as a binary, finally the non-secure.

As a result of the secure build an object file with the veneers is generated which is then linked to the non-secure image.

Run the Example

To run the example on the V2M-MPS2 board you need to load both the secure and non-secure images onto the board.

Output from the examples are printed to the serial port:

    UART0 serial port at 115200 baudrate (8N1).

Programming the board

To program the MPS2 board, follow these steps:

  • Copy the <secure>.axf and <non_secure>.axf files generated during compilation in <MPS2 device name>/SOFTWARE/
  • Go to <MPS2 device name>/MB/HBI0263<board revision letter>/AN521/ folder
  • Open the <MPS2 device name>/MB/HBI0263<board revision letter>/AN521/images.txt file
  • Update the "TOTALIMAGES: " with "TOTALIMAGES: 2"
  • Add/update the "IMAGExADDRESS:" and "IMAGExFILE:" settings with the location and the binary names. You should have similar to this:
TITLE: Versatile Express Images Configuration File

[IMAGES]
TOTALIMAGES: 2                   ;Number of Images (Max: 32)

IMAGE0ADDRESS: 0x00000000
IMAGE0FILE: \Software\tfm_s.axf  ; TF-M example application secure binary
IMAGE1ADDRESS: 0x00000000
IMAGE1FILE: \Software\tfm_ns.axf ; TF-M example application non-secure binary
  • Close the images.txt file
  • Eject the usb device
  • Reset the board

Note: axf file names need to fit in the 8.3 file name format required by MPS2, and filenames generated must be lower case

Debugging

Please note that Keil Debug of these examples will only work with FPGA image for SSE-200 IoT Subsystem for Cortex-M (AN521) Version 3.0 or later.

Debugging has only been tested with ULINK Pro Debugger. To enable it, ensure the following debug settings:

  • Right-click on the project name you want to debug and "Set as Active Project".
  • Go to menu "Project" -> "Options for <project_name>".
  • Go to "Debug" tab and select ULINK Pro Debugger.
  • Go to "Settings" and under the "Debug" tab un-tick both "Cache Options", "Cache Code" and "Cache Memory".
  • Under "Flash Download" tab, select "Do not Erase" in "Download Function" and un-tick "Program", "Verify" and "Reset and Run".
  • On the main project Window start debugging in "Debug" -> "Start/Stop Debug Session".

See the ReadMe file provided with the example for further information.

  • Share
  • History
  • More
  • Cancel
Related
Recommended