How do I avoid variable (or file) name conflicts when using multiple copies of library subsystems with To Workspace (or To File) blocks?
古いコメントを表示
I am creating a model and using a subsystem that I created and placed in a custom library. This subsystem has a To Workspace block in it that has the default variable name as 'simout'. Thus this block will save data to a variable named 'simout' in the MATLAB workspace.
The problem is that when I use two copies of this subsystem block, I now face a naming conflict as two blocks are trying to save data to the same variable. In order to change the variable name, I need to break the library link. However, I need to retain the library link as I need to make changes to the subsystem block.
The same issue arises if I have a To File sink block instead of a To Workspace block in my library subsystem.
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Programmatic Model Editing についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!