If statement stateflow (Action language C vs. MATLAB)

17 ビュー (過去 30 日間)
Frank F.
Frank F. 2022 年 9 月 27 日
回答済み: Jagadeesh 2022 年 9 月 28 日
Is it possible to use an if statemant in stateflow with action language C? Also without an end and with {} the if statement does not work...
With action language MATLAB there is no problem...

採用された回答

Jagadeesh
Jagadeesh 2022 年 9 月 28 日
Hey Frank,
Conditional and loop control statements are not supported in State Actions with C as the Action Language. You can find this and other functional differences between the action languages in the table ”Compare Functionality of Action Languages” here: https://www.mathworks.com/help/stateflow/ug/differences-between-matlab-and-stateflow-action-language.html
In order to achieve conditional and loop patterns in Stateflow, please use Graphical Functions instead. For more information on implementing Graphical Functions, you may refer to: https://www.mathworks.com/help/stateflow/ug/graphical-functions-for-reusing-logic-patterns-and-iterative-loops.html

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeComplex Logic についてさらに検索

製品


リリース

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by