How can i add simscape block programmatically

10 次查看(过去 30 天)
I konw how to add the basic simulink block programmatically. But when i use the same method, there is always something went wrong with the path name of the block source. How should i specifiy the name of the block source path properly?
add_block('simscape/Electrical/Specialized Power Systems/Fundamental Blocks/Mutual Inductance','Model_auto_generation_Mutual_inductance_considered')
Unbenannt.png
  2 个评论
Yifeng Tang
Yifeng Tang 2019-11-26
If you open Simulink Library and hover the mouse over the block you want, the proper block path will show up.
Sam
Sam 2019-11-26
Hi Yifeng,
Thanks for your answer. It worked.

请先登录,再进行评论。

回答(1 个)

Steve Miller
Steve Miller 2020-8-17
Looks like Yifeng's comment answered your question:
If you open Simulink Library and hover the mouse over the block you want, the proper block path will show up.
If you have a follow-up question, let us know.

类别

Help CenterFile Exchange 中查找有关 Foundation and Custom Domains 的更多信息

产品


版本

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by