How to package generate code and header files on the basis of subsystems?

2 ビュー (過去 30 日間)
Soham Sinha
Soham Sinha 2022 年 1 月 25 日
回答済み: Mark McBroom 2022 年 1 月 29 日
Suppose, I have two subsystems in my model: SubA and SubB, how can I generate and create two subfolders, named SubA and SubB, which will contain all the required model header and C source files, even if they are redundant to be produced for the two subfolders?

回答 (1 件)

Mark McBroom
Mark McBroom 2022 年 1 月 29 日
It is not possible to have the code for SubA and SubB be placed in 2 different subfolders. However it is possible to have the code for each subsystem be placed in seperate C/C++ and H files. YOu need to make the subsystem "atomic" and then use the code generation tab to configure code generation for the subsystem. https://www.mathworks.com/help/simulink/slref/subsystem.html

カテゴリ

Help Center および File ExchangeSimulink Coder についてさらに検索

製品


リリース

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by