Skip to content

This repository contains a traffic light example application demonstrating safety features. It runs on Infineon TRAVEO T2G hardware.

License

Notifications You must be signed in to change notification settings

Arm-Examples/Safety-Example-Infineon-T2G

Repository files navigation

Build T2G Release

Safety Example for Infineon TRAVEO T2G Series

This repository contains examples for Keil Studio that run on the Infineon Kit T2G-B-H_Lite.

Quick Start

  1. Install Keil Studio for VS Code from the VS Code marketplace.
  2. Clone this Git repository into a VS Code workspace.
  3. Open the CMSIS View in VS Code and use the ... menu to choose an example via Select Active Solution from workspace.
  4. The related tools and software packs are downloaded and installed. Review progress with View - Output - CMSIS Solution.
  5. Patch T2G-B-H_DFP as explained in the Patch/README.md
  6. In the CMSIS view, use the Action buttons to build, load and debug the example on the hardware.

Examples

The examples can be explored using the Keil MDK Community edition that is free-to-use for training and evaluation. For evaluation purposes, the open-source variant of Keil RTX is used which offers the similar features as the commercial, safety-certified FuSa RTS. FuSa RTS is part of the Keil MDK Professional edition.

NOTE

The CMSIS-Driver Ethernet accesses a variable in the Infineon DFP that is defined static in the current implementation. Therefore remove the static attribute in the file %CMSIS_PACK_ROOT%/Infineon/T2G-B-H_DFP/1.2.1/Libraries/mtb-pdl-cat1/drivers/source/cy_ethif.c as explained in Patch/README.md. For CI this patch is applied as part of the Build_T2G_Release workflow.

App/T2G

This is a practical demonstration of Arm FuSa RTS process isolation, using a simple traffic light controller to showcase safety classes, MPU zones, and fault handling on Cortex-M devices.

The App/T2G.csolution.yml safety example uses three processor cores and contains:

App_T2G Safety Example

The safety-critical application part CM7_0_TrafficLight uses safety classes to protect safe-mode operation. A web interface allows you to inject faults for testing the system recovery features. This part of the example is based on the application note KAN336 - TrafficLight: Arm FuSa RTS process isolation example.

This example application uses the Memory Protection Unit (MPU) and the Thread Watchdog available with FuSa RTS. It does not use:

The usage of SMPU and PPU is explained in the application note from Infineon AN219843 - Protection Configuration in TRAVEO T2G.

Test/CMSIS_DV

The Infineon DFP/BSP software packs do not contain a CMSIS-Driver Ethernet or board software layers. These components are therefore developed separately and provided in this repository.

The Test/CMSIS_DV.csolution.yml validates the CMSIS-Driver Ethernet with the CMSIS-Driver_Validation pack.

Git Workflow

This repository contains multiple csolution projects and is configured as a single Git workspace for VS Code. It can be therefore effectively used with the VS Code Git integration via the following files:

  • vcpkg-configuration.json is in the workspace root directory and installs the tools for all csolution projects.
  • .gitignore excludes files that contain user specific setup, for example .vscode and *.cbuild*.yml.

Continuous Integration (CI) and Hardware-in-the Loop Test

The underlying build system of Keil Studio uses the CMSIS-Toolbox and CMake. CI is effectively supported with:

CI and HiL Test

CI Workflow Description
Build_T2G_Release.yaml Compile application using a GitHub action and save build output (artifacts).
Run_T2G_Release.yaml Download to a Linux box and execute the application on Infineon Kit T2G-B-H_Lite.

Files and Directories

This is a list of the relevant files and directories.

File/Directory Content
vcpkg-configuration.json Defines the tools that the Arm Tools Environment Manager installs in VS Code.
App App/T2G contains the safety example.
Doc Documentation files.
Patch Patch for the T2G-B-H_DFP pack.
Test Test/CMSIS_DV contains the validation for the CMSIS-Driver Ethernet.
.github/workflows Contains setup for the CI Build and HiL test workflows.

Webinar

This example was explained in the Multicore and FuSa Development with TRAVEO™ T2G:

Multicore webinar preview

Issues or Questions

Use the Issues tab to raise questions or issues.

About

This repository contains a traffic light example application demonstrating safety features. It runs on Infineon TRAVEO T2G hardware.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Contributors 6