Distributed Model Code Generation Options
Distributed models allow you to model complex systems as individual components and simulate the components at different sample times or cycle rates. The Simulink® PLC Coder™ distributed model code generation options allow you to generate structured text code for individual components of the model and integrate the generated code externally. Use this table to decide the code generation option to use based on your distributed model design and requirements.
Generate code for individual model subsystems and integrate the generated code externally.
Prevent initialization of externally defined variables.
The distributed code generation options are model-specific, and when selected at the top level, are enabled for all the model subsystems. Once you enable the option, it stays on. When generating code for individual subsystems, you might see unintended behavior in the generated code due to the option remaining on.