Editing default simulink libraries

5 次查看(过去 30 天)
I'm running version 2013b and I'd like to modify the default Simulink libraries for styling and ease of use. An example of this is input and output port colors (green for input, red for output) or removing the data limiting in the default Simulink scopes. One way I can edit them is to manually change the simulink.slx and simviewers.mdl files within the MATLAB folder structure, but this requires administrative permissions on the files. Is there another way to edit these kinds of properties in the default libraries?

回答(1 个)

Ilham Hardy
Ilham Hardy 2016-2-1
编辑:Ilham Hardy 2016-2-1
Is that even possible/allowed?
What I usually do is using script to give the model "make-over" by using find_system(),
list all the specified blocks and edit them using set_param() in the for-loop..
  1 个评论
Jonathan Adams
Jonathan Adams 2016-2-1
In theory this would work for some of the styling changes, and honestly making a custom default library would probably work for styling/mask parameter changes to default blocks. This solution doesn't work for attaching a viewer to a signal. (right click signal -> Create and Connect Viewer -> Simulink -> Scope)
This scope isn't the same as the scope block in the "Sinks" library and resides in a different library file. (simviewers.mdl) If you've ever wanted to see more than the default limited number of data points you have to manually deselect this in the scope properties every time you attach a scope.
In version 2010a all of these libraries were available for modification, but in 2013b the user's permissions were restricted to read and execute. An administrator must grant the user access to modify the files. I can understand why this would be restricted; I wondered if anyone knew a way within MATLAB to change library defaults.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Simulink Functions 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by