フィルターのクリア

Struct variables are generated inconsistently with Embedded Coder

2 ビュー (過去 30 日間)
Ghassen
Ghassen 2024 年 5 月 15 日
コメント済み: Fangjun Jiang 2024 年 5 月 15 日
I am trying to generate a C++ code for my Simulink model. Everything works fine, but the problem I have is that the struct name that is generated is not consistent, and I am not sure what the problem is, although I have not changed anything in the Embedded Coder Configurations.
For example:
Before the struct was generated as follows:
struct ExtY_moduleName_T
Now it's just:
struct ExtY
Or
// Parameters (default storage)
struct P_moduleName_T
Now it's just:
// Parameters (default storage)
struct P
How can I keep this consistent, what causes the _moduleName identifier to be removed ? I checked under Settings -> Code Generation -> Identifiers and this is what I got:
On the left are the expected values and on the right are the new values (without _moduleName), why did it change ?
I'm using Matlab R2023b.

回答 (1 件)

Fangjun Jiang
Fangjun Jiang 2024 年 5 月 15 日
That can be explained by the "$N$R$M_T" on the left and "$N$M" on the right for "Global types". "$R" means root model name. "_T" is explicit suffix.
What do you mean by "expected" and "new". They are two model configurations. They are apparently different or has been changed for naming rules for "Global types".
  2 件のコメント
Ghassen
Ghassen 2024 年 5 月 15 日
This means that the configurations change by themselves for some reason. Last week they were the same as those shown on the left.
Fangjun Jiang
Fangjun Jiang 2024 年 5 月 15 日
Left side seems to be the default for ert.tlc.

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

カテゴリ

Help Center および File ExchangeDeployment, Integration, and Supported Hardware についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by