Error: Error occurred when checking data object usage for model
5 ビュー (過去 30 日間)
古いコメントを表示
Error: Error occurred when checking data object usage for model 'VCU_App': The specified owner models for the following internal signals/states used by model 'VCU_App' must have access to the data: Signal 'Ctrl_VCU_SF1' is set to an invalid owner 'Ctrl_VCU_SF'
Hello,
I have a structure where I have a Top Model called VCU_App, and inside it I have referenced models for various functionalities that I want to code in separate source files
For this purpose I use in Embedded Coder the class ExportToFile for the Inports, Outports for each referenced model so that they are declared, defined in the respective model source files.
I already did this for some models, and I used as Owner in the Code Mappings the name of that model.
But now I made a new model Ctrl_VCU_SF, and I am receiving the error above when trying to generate code.
The only difference that I see is that this model has its inputs connected to ground blocks, and its output is connected to a terminator
Any idea what this means and how to fix it?
I tried to remove the Owner from the Code Mappings, and the code is generated, but I noticed that new .c, .h files are generated now just with the declaration and the definition of that variable, but they are located in the folder where the code for the Top App is.
Further more, this is crashing my compilation as I have the same files twice, and it also doesn't make sense to me.
0 件のコメント
回答 (1 件)
Mark McBroom
2022 年 5 月 2 日
Since the top model VCU_App needs to interact with the child models using the same exported signals, you'll need to set owner of the data objects for the child model to also be VCU_App. Alternately, you could remove the storage classes for the child model inports and outports since presumbly you likely only care about the storage for the top level model root level ports and interfaces.
参考
カテゴリ
Help Center および File Exchange で Deployment, Integration, and Supported Hardware についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!