Main Content

PIL Execution with ARM Cortex-A by Using the MATLAB Coder App

You can use processor-in-the-loop (PIL) executions to verify generated code that you deploy to target hardware by using a MATLAB® Coder™ procedure. You can profile algorithm performance and speed for your generated code. To verify generated code with the MATLAB Coder app, you must have an Embedded Coder® license.

This PIL execution is available with these hardware support packages. To use the PIL execution, install one of these support packages.

  • Embedded Coder Support Package for BeagleBone® Black Hardware

  • Embedded Coder Support Package for ARM® Cortex®-A Processors

You can set up PIL execution with the MATLAB Coder app.

To configure the build type and hardware board:

  1. In the Prepare section of the MATLAB Coder tab of the toolstrip:

    • Set Output type to Static Library (.lib).

    • Set Settings > Hardware Board to BeagleBone Black or ARM Cortex-A9 (QEMU).

  2. If necessary, modify the settings for your board. To modify the settings, click Settings > View all settings, and then click Hardware.

  3. To generate the library, click Generate Code > Generate Code and Build.

  4. Set up your PIL execution.

    • Make sure Verification mode is set to Use generated code.

    • In the Verify section of the toolstrip, use the Run Using PIL > Run file option to specify the test file that calls the original MATLAB functions, for example, test01_ui.m. PIL execution starts automatically.

  5. To stop the PIL execution, click Stop.

For another example of PIL verification, see the "Processor-in-the-Loop Verification of MATLAB Functions" page in the documentation of the Embedded Coder Support Package for ARM Cortex-A Processors. Install the support package to view the documentation.