Initialize関数のカスタマイズ
조회 수: 3 (최근 30일)
이전 댓글 표시
Simulinkモデル内の、サブシステムをInitialize関数の処理として組み込みたい場合、どのようにすればいいでしょうか。
댓글 수: 0
답변 (1개)
Toshinobu Shintai
2021년 1월 6일
Simulinkライブラリブラウザーの「Simulink」「User-Defined Functions」にある「Initialize Function」ブロックを使うことで実現できます。
添付ファイルにサンプルモデルを作成してみました。「my_system.slx」は、Embedded Coderでコード生成する設定がなされていますので、コード生成すると、「Initialize Function」ブロックの中の処理がmy_system_initialize関数の中に記述されます。
モデルはR2020bで作成しました。
댓글 수: 2
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!