필터 지우기
필터 지우기

Using replace_block with Simscape

조회 수: 1 (최근 30일)
Cedric Götze
Cedric Götze 2015년 7월 16일
댓글: Cedric Götze 2015년 7월 16일
I want to replace a simscape block with another one. This doens't work:
replace_block('vdp','Constant Area Pneumatic Orifice','fl_lib/Pneumatic/Pneumatic Elements/Variable Area Pneumatic Orifice','noprompt')
What am I doing wrong? Thanks in Advanced

채택된 답변

Sebastian Castro
Sebastian Castro 2015년 7월 16일
Just tried the same command as you and it works fine on my end... although the block name stays the same. Is that maybe the case for you too?
- Sebastian
  댓글 수: 1
Cedric Götze
Cedric Götze 2015년 7월 16일
replace_block('vdp',sprintf('Constant Area\nPneumatic Orifice'),'fl_lib/Pneumatic/Pneumatic Elements/Variable Area Pneumatic Orifice','noprompt')
I found out, the \n was missing. This way it works!
Thanks

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Electromagnetic Models에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by