Main Content

Get Started with Embedded Coder Support Package for ARM Cortex-R Processors

This example shows how to use Embedded Coder® Support Package for ARM® Cortex-R Processors to run Simulink® models on a TI™ Hercules RM57Lx LaunchPad Development Kit.

Introduction

The Embedded Coder Support Package for ARM Cortex-R Processors enables you generate code from Simulink models. You can compile and load the generated code as an executable on an ARM Cortex-R5F processor in theTI Hercules RM57Lx LaunchPad Development Kit. Then, you can run the executable of the development kit.

Requirements

Configure Model for Code Generation on ARM Cortex-R

This section shows you how to configure a Simulink model to build, deploy, and run as an executable on the TI Hercules RM57Lx LaunchPad Development Kit.

1.Open thearm_cortex_r_gettingstartedmodel. This model uses a simplified ring-oscillator to generate a squarewave with the frequency specified as an input.

3. On theAppstab in the Simulink Toolstrip, in theSetup to Run on Hardwaregroup, clickRun on Hardware Board.

4. On the Run on Hardware Board dialog box, setHardware Boardto TI Hercules RM57Lx LaunchPad. ClickFinish.

Build, Deploy and Start Executable on ARM Cortex-R

The Embedded Coder software, using the GCC toolchain, can build a binary executable by compiling and linking the generated code on your host computer. Then, you can deploy and run the executable on an ARM Cortex-R processor. On theHardwaretab, clickBuild, Deploy & Startto run your model as a binary executable on the running the TI Hercules RM57Lx LaunchPad Development Kit.

After the model launches on the hardware, a command window opens and shows that the executable is running on in the TI Hercules RM57Lx LaunchPad Development Kit. To stop the model running on the TI Hercules RM57Lx LaunchPad Development Kit, close the command window.

Other Things to Try

You can interact with the code running on the TI Hercules RM57Lx LaunchPad Development Kit using external mode or PIL. For more information on external mode and PIL with the ARM Cortex-R, seeProcessor-in-the-Loop Verification of Simulink ModelsandParameter Tuning with External Mode Simulation.