How to force a Simulink model to update all its linked model subsystems to the latest/current library
Show older comments
All,
I'm having a frustrating problem and have lost countless hours of time... I build Simulink models that reference subsystems from libraries. Sometimes these libraries reference other libraries so there is a hierarchy. I frequently have a problem where the simulation of the top calling model does not have the latest library subsystem linked in. I started the practice of calling,
bdclose(find_system('type', 'block_diagram','BlockDiagramType','library'));
before running each simulation. This has helped but work 100% of the time. I still get into situations where I'll make an edit to a library subsystem only to find that when I run the calling Simulink model those edits aren't present.
Can someone please explain how I can force Simulink to recursively traverse the hierarchy of linked library subsystems and force them all to update to the current state of the saved library?
Thank you.
EDIT: I should have posted this question here: https://www.mathworks.com/matlabcentral/answers/95765-how-can-i-force-my-simulink-model-to-use-the-latest-version-of-the-library-in-simulink-6-3-r14sp3
3 Comments
Joe
on 4 Oct 2017
Carl
on 13 Oct 2017
Hi Joe, the link below might be helpful. The author has a few articles about the scalability of Simulink libraries:
https://blogs.mathworks.com/simulink/category/libraries/
Saulat Chughtai
on 24 Jan 2020
Same with me nothing is working if we have hierarchy of linked libraries. Interestingly, if I open the intermediatry library save it and close it then it works from the command window but if put the seame commands in start up file from simulink project nothing happens.
Really furustrated.......
Answers (0)
Categories
Find more on Using MATLAB Projects in Simulink 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!