- Create a simple System object with getIconImpl that defines the icon based on a Logical property value.
- Create a Simulink library and add MATLAB System block
- Create a subsystem from the block and create mask
- In Mask, promote checkbox parameter from System block
- In new model, drag block from library
- Open block dialog and look under mask
- The System block icon stays the same even when toggling and applying the new checkbox value on the dialog.
getInputNamesImpl() uses stale data when System Object in library mask
1 view (last 30 days)
Show older comments
Scenario:
Subsystem is created that contains 2 custom SystemObjects.
Subsystem has mask parameters that contain info that should be displayed on input/output ports (or icon) for the internal SystemObjects.
Information is correctly propagated for the subsystem until....
...I put it into a Simulink library. Now, when the library's default mask parameters differ from the Simulink model mask parameters (which will always be the case), the System Objects inside the mask in the model no longer get the correct information.
This appears to be a bug, as the behavior is very non-intuitive. There are other mask parameters that feed into the SystemObject which affect the actual functionality, and those are properly handled. It appears that getInputNamesImpl(), getOutputNamesImpl(), and getIconImpl() all do not properly get info from the operational model, but rather from stale data from the library.
1 Comment
Jacob Halbrooks
on 25 Jul 2016
I think I have reproduced this issue but would like to confirm the steps with you:
Does this capture your basic workflow?
Answers (0)
See Also
Categories
Find more on Interactive Model Editing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!