Main Content

Simulink PLC Coder

Generate structured text and ladder diagram code from Simulink models, Stateflow charts, and MATLAB functions

Since R2019b

Description

To generate structured text code or ladder diagram code, use the PLC Coder app. When you open the app, a PLC Code tab is added to the toolstrip. The PLC Code tab contains sections that represent steps of the Simulink PLC Coder workflow. You can iterate though model preparation for code generation, code generation and builds, and code verification by using the editor window panels.

Use the app to:

  • Configure model-wide code generation parameter settings. Click Settings.

  • Generate code. Select Generate PLC Code.

  • Review generated code. Click Open Report.

Simulink PLC Coder App

Open the Simulink PLC Coder App

In the Apps gallery, under Code generation, click PLC Coder.

Version History

Introduced in R2019b