How to change model properties of a .slx simulink model using the MATLAB script
13 views (last 30 days)
Sachin Ganesh Uma Maheswaran on 3 Mar 2021
I am working on automated test scripts which involve calling mulltiple simulink models from inside a single simulink model. So I would like to access and edit the model porperties of all these simulink files at once using a matlab script.
For example, in the picture, I want to change the design Data definition from Base Workspace to Data Dictionary without having to open the simulink model and going to model properties, but directly from the command window. Does anyone know a way for it?
Mark McBroom on 6 Mar 2021
Model configuration settings can be controlled from MATLAB code using the get_param() and set_param() functions. Help will tell you the name of the parameter. In this case: