Embedded Coder - Simulink.Parameter declaration
显示 更早的评论
When I generate autocode for the using the TI C2000 toolchain, all Simulink.Parameter variables in the model are declared as 'extern' in the model header file. I.E. if I have a variable x, when i generate code, the header file will have a line that says something like extern int x; No matter what datastorage method I use, the end result is that the variable is some kind of extern (Simulink Global puts the variable into a structure, and then the structure has an extern declaration).
Because we are using Model Based Development to create code for aerospace applications, any global declarations are not allowed. How do I get Simulink to generate code where Simulink.Parameter values are created inside the model's function (i.e. so the variables are not accessible by other functions).
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Simulink Coder 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!