Export a Simulink model with an FMU interface
古いコメントを表示
I have to create an FMU interface to export a Simulink model. I've downloaded the software from the website https://www.fmi-standard.org/downloads. It requires the xml file and the C-source of the simulink model. When I run the software to create the FMU the error message is
"simstruc.h<285> : fatal error C1189: #error : Unrecognized use"
I've created the xml file using the command "savesystem" in MATLAB. For the C file I've used the target rsim because I used a variable integration step.
MATLAB version used R2011b.
Thanks a lot. Alessandro.
回答 (1 件)
Kaustubha Govind
2012 年 10 月 16 日
0 投票
It looks like you may have non-inlined S-functions in your model that the build is unable to handle. What is the System Target File selected in the Configuration Parameters>Code Generation pane?
14 件のコメント
Alessandro
2012 年 10 月 16 日
編集済み: Alessandro
2012 年 10 月 16 日
Kaustubha Govind
2012 年 10 月 17 日
Alessandro
2012 年 10 月 26 日
Kaustubha Govind
2012 年 10 月 26 日
What is the C/C++ compiler command being use?
Alessandro
2012 年 10 月 26 日
Kaustubha Govind
2012 年 10 月 29 日
Alessandro: Can we stick to debugging with grt.tlc+MSVC?
Alessandro
2012 年 11 月 5 日
Kaustubha Govind
2012 年 11 月 5 日
I meant to ask you to try the build without using the "build_fmu me sistMCK" command. Just use the default Simulink Coder build process.
Alessandro
2012 年 11 月 5 日
Alessandro
2012 年 11 月 15 日
Kaustubha Govind
2012 年 11 月 15 日
Alessandro: Are you saying that you are seeing the exact same error using the default Simulink Coder build process (ie. without using a custom command like "build_fmu me sistMCK")?
Alessandro
2012 年 11 月 15 日
Kaustubha Govind
2012 年 11 月 15 日
You probably need to fix the Makefile used with the fmu build process to define the right symbol. I would recommend looking at the default Makefile generated by Simulink Coder. In particular look for the symbols used in the seven #ifs that you posted to find which of those you need to define at compilation.
Sathish Kumar Vadivel
2018 年 3 月 22 日
Is there already a solution available for this issue ? Thanks Sathish
カテゴリ
ヘルプ センター および File Exchange で FMU Importing についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!