MATLAB Answers

help, with code generation for TI C2000

4 ビュー (過去 30 日間)
Carlos Noriega
Carlos Noriega 2020 年 7 月 11 日
コメント済み: Jonas 2020 年 8 月 4 日
Hi Please,when i generate to code to TI C2000, What type of configuration does simulink need for the generate algorithm code, with all chart conditions?
I'am using Chart for control algorithm, and I need send the code generation for TI C2000, through code generatios of simulink window.
I can a generate code, but I look that generated code is missing several conditions and operations.

  1 件のコメント

Venkatesh Chilapur
Venkatesh Chilapur 2020 年 7 月 13 日
Hi,
Please contact:
Regards,
Venkatesh C

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

採用された回答

Jonas
Jonas 2020 年 7 月 13 日
Hi Carlos
If the issue is just that some states and/or transitions you have programmed in Stateflow do not appear in the generated code, then I just think the Embedded Code generator optimized those states out of the code since they are never reached or used. This aspect of the code generator is called 'block reduction'.
If you have a transition with the condition [false] for example, the transition is never made and the code generator may chose to not generated code of it.
Some background info:
With kind regards,
Jonas

  4 件のコメント

表示 1 件の古いコメント
Jonas
Jonas 2020 年 7 月 14 日
The variable P is a uint16 while Pp is a double, you are doing Pp = P which is not correct Data Type wise.
This has nothing to do with the Configuration Parameters.
Carlos Noriega
Carlos Noriega 2020 年 7 月 24 日
Hi Jonas, I was wondering if you might be able to give me some advice.
Jonas
Jonas 2020 年 8 月 4 日
Explicitly set the data type of the variables of your stateflow chart using the Model Explorer.

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

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by