possibility to create "Enbaled" subsystem
이전 댓글 표시
Hello all,
I need to create the subsystem which needs to be optionally Enable/Disabled before simulation starts but there si no need to be enabled/disable during the simulation ...
What are the possiblities to create a such subsystem in Simulink?
Thank you very much for your suggestion.
채택된 답변
추가 답변 (1개)
Paul
2025년 1월 15일
0 개 추천
One option would be to create the subsystem as an Enabled subsystem and then control the enable port with a signal that you control from the worksapce (or from however you're injecting data into the simulation) such that the block is either enabled or disabled for the entire simulation. Keep in mind that the block outputs are still going to be generated for the entire simulation.
Another option would be to not use an Enabled subsystem and instead use a call to set_param to set the Commented property of the subsystem to the behavior you want ('off', 'on', or 'through'). I believe that toggling this parameter is a structural change and so will cause the simulation to be rebuilt/recompiled when that parameter changes.
카테고리
도움말 센터 및 File Exchange에서 Component-Based Modeling에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!