Verification

Simulation and verification of Structured Text against original model

Functions

plcdispextmodedataDisplay the external mode logging data
plcrunextmodeRun external mode visualization

Examples and How To

Verify Using Test Benches

Import Structured Text Code Automatically

Open generated code directly in your IDE instead of manually importing the generated code files.

Import and Verify Structured Text Code

Verify generated code against the original Simulink® model in your IDE using a generated test bench.

Verify Generated Code That Has Multiple Test Benches

Provide multiple signal groups as subsystem input so that multiple test benches are generated for code verification.

Integrate Generated Code with Custom Code

Call the generated function block with different values of the ssMethodType argument for subsystem initialization and computation steps.

Verify Using Code Generation Report

Create and Use Code Generation Reports

Generate traceability report for navigating between model and code, and code metrics report for static code metrics such as lines of code and number of function block inputs.

View Requirements Links from Generated Code

View links to requirements documents in your model as comments in the generated Structured Text code.

Verify Using External Mode Logging

External Mode Logging

Collect run-time data, visualize, and monitor logging data for Rockwell PLC targets.

Generate Structured Text Code with Logging Instrumentation

Workflow for generating structured text code with logging instrumentation.

Use the Simulation Data Inspector to Visualize and Monitor the Logging Data

Visualize and monitor the logging data for Rockwell targets.

Concepts

How Test Bench Verification Works

Learn how to verify that the generated Structured Text code is equivalent to the original Simulink model.

Information in Code Generation Reports

Learn about navigation between model and generated Structured Text code using code generation reports.

Working with the Static Code Metrics Report

Check the information in the code metrics reports and decide if the generated Structured Text code is ready for deployment.

Using Simulink Test with Simulink PLC Coder

Workflow for using Simulink Test with PLC Coder.