| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Real-Time Workshop Embedded Coder |
| Contents | Index |
| Learn more about Real-Time Workshop Embedded Coder |
Attach model-specific C++ encapsulation interface to loaded ERT-based Simulink model
attachToModel(obj, modelName)
attachToModel(obj, modelName) attaches a model-specific C++ encapsulation interface to a loaded ERT-based Simulink model.
| obj | Handle to a model-specific C++ encapsulation interface control object, such as a handle previously returned by obj = RTW.ModelCPPArgsClass or obj = RTW.ModelCPPVoidClass. |
| modelName | String specifying the name of a loaded ERT-based Simulink model to which the object is going to be attached. |
The Configure C++ Encapsulation Interface button on the Interface pane of the Simulink Configuration Parameters dialog box launches the Configure C++ encapsulation interface dialog box, where you can flexibly control the C++ encapsulation interfaces that are generated for your model. Once you validate and apply your changes, you can generate code based on your C++ encapsulation interface modifications. See Generating and Configuring C++ Encapsulation Interfaces to Model Code in the Real-Time Workshop Embedded Coder documentation.
Configuring C++ Encapsulation Interfaces Programmatically in the Real-Time Workshop Embedded Coder documentation
Sample M-Script for Configuring the Step Method for a Model Class in the Real-Time Workshop Embedded Coder documentation
Controlling Generation of Encapsulated C++ Model Interfaces in the Real-Time Workshop Embedded Coder documentation
![]() | attachToModel (RTW.AutosarInterface) | attachToModel (RTW.ModelSpecificCPrototype) | ![]() |

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |