No constructor 'Stateflow.State' with matching signature found.

1 回表示 (過去 30 日間)
Lucas S
Lucas S 2019 年 7 月 4 日
編集済み: Filip Toman 2019 年 7 月 23 日
Hello !
I'm trying to create State block :
chart = add_block('sflib/Chart', 'autoDS/Chart');
state = Stateflow.State(chart);
state.Name = 'CMD_28V_Avion';
open_system('autoDS');
It returns me "No constructor 'Stateflow.State' with matching signature found" error.
How can i fix it please ? I'm pretty sure it's not a syntax error
Thank you !
  1 件のコメント
Filip Toman
Filip Toman 2019 年 7 月 23 日
編集済み: Filip Toman 2019 年 7 月 23 日
curr_chart = m.find('-isa', 'Stateflow.Chart', '-and', 'Name', 'chart_if_test_0');
curr_chart.view;
You first need to find the chart, then inspect it with view. I think if you use add_block you are using a Simulink command that probably returns the handler instead of the real object. Afterwards you can use constructors on object curr_chart.

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeStateflow Programmatic Interface についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by