About cookies on this site Our websites require some cookies to function properly (required). In addition, other cookies may be used with your consent to analyze site usage, improve the user experience and for advertising. For more information, please review your options. By visiting our website, you agree to our processing of information as described in IBM’sprivacy statement. To provide a smooth navigation, your cookie preferences will be shared across the IBM web domains listed here.
Product Documentation
Abstract
The default code generation settings in MATLAB SImulink are not compatible with Rhapsody. To import a Simulink model (and its generated code) into a Rhapsody SimulinkBlock you must manually change the settings in each Simulink Model.
However, you can use Configuration Sets to add these as presets to a Simulink model without having to remember each setting.
The Configuration Set used in this guide can be found at the bottom of the page, along with the example MATLAB project.
Content
-
Here we have a two Simulink models in a MATLAB project:
-
Open both of the Simulink models and from one of the model windows, select the "Model Explorer" button on the toolbar:
-
Right-click a Simulink model and select "Import...".
-
Browse to the RhapsodyCodeGenConfigSet.mat file (you can find the file for download at the bottom of this page) and open it.
-
The configuration file is added to the Simulink Model view. You can rename it if you wish.
Note the default Configuration Set is still present in the model view. Before we can delete it we should make the new Configuration set active.
-
Right-click the Configuration Set and select Activate.
-
Right-click the Simulink model in the viewer and select "Save".
-
Repeat steps 3-7 for each Simulink model.
Note, Simulink may require other settings to be used depending on the type of model you have created. These issues will be highlighted during Simulink code generation. For example, "Fixed" or "Variable" step settings may be invalid for the type of Simulink model. Please follow Simulink instructions to correct any issues that may arise.
[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSB2MU","label":"IBM Engineering Systems Design Rhapsody"},"Component":"","Platform":[{"code":"PF033","label":"Windows"}],"Version":"8.1.5;8.2;8.2.1;8.3;8.3.1","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]
Product Synonym
Rational Rhapsody
Was this topic helpful?
Document Information
More support for:
IBM Engineering Systems Design Rhapsody
Software version:
8.1.5, 8.2, 8.2.1, 8.3, 8.3.1
Operating system(s):
Windows
Document number:
715997
Modified date:
27 May 2022
UID
ibm10715997
Manage My Notification Subscriptions