defining simulink variables through matlab srcript
1 回表示 (過去 30 日間)
古いコメントを表示
how can I define variables through matlab script? I am using trial version
0 件のコメント
回答 (1 件)
galaxy
2019 年 10 月 29 日
You can create variables to workspace and in simulink, enable acess to base workspace.
For create variables via script, let 's try as following
v = genvarname('name_variable', who);
eval([v '= 1']); %% assign variable value
2 件のコメント
galaxy
2019 年 10 月 30 日
You must using "name_variable" in simulink model which same as workspace, and in model, please acess to base workspace as following
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!