Main Content

SIL/PIL Manager

Verify generated code

Description

The SIL/PIL Manager simplifies verification of code that you generate from a model.

You can:

  • With one click, test numeric equivalence between the model and generated code by running back-to-back model simulations and software-in-the-loop (SIL) or processor-in-the-loop (PIL) simulations.

  • Configure SIL or PIL simulations to produce code coverage, execution-time, and stack usage metrics.

  • Enable your debugger for SIL simulations.

  • Export automatically generated test cases for Simulink® Test™.

SIL/PIL Manager app

Open the SIL/PIL Manager App

On the Simulink toolstrip Apps tab, click SIL/PIL Manager. Or, on the Embedded Coder app C Code tab, click Verify Code > SIL/PIL Manager.

Examples

expand all

  1. In the Command Window, enter rtwdemo_sil_topmodel.

  2. To open the SIL/PIL Manager, on the Apps tab, click SIL/PIL Manager.

  3. On the SIL/PIL tab, use the supplied settings.

  4. In the Run Automated Verification section, click Run Verification.

  1. In the Command Window, enter rtwdemo_sil_modelblock.

  2. To open the SIL/PIL Manager, on the Apps tab, click SIL/PIL Manager.

  3. On the SIL/PIL tab, use the supplied settings.

  4. Open the Results gallery. In the Results section, click either Compare Runs or Data Inspector.

  5. Under Simulink Test, click Export to Test Manager.

  6. In the Export SIL/PIL Test Cases dialog box, use the default settings, and click OK.

  1. In the Command Window, enter rtwdemo_sil_topmodel.

  2. On the Apps tab, click SIL/PIL Manager.

  3. In the Mode section, select SIL/PIL Simulation Only.

  4. In the Prepare section, open the Settings gallery:

    1. Under Profiling, click the Task Profiling button off.

    2. Under Coverage, click the Coverage Collection button off.

    3. Under Stack Profiling, click the Stack Profiling button on.

  5. In the Run section, click Run SIL/PIL.

Related Examples

Version History

Introduced in R2019b