Parameters from MATLAB function in Simulink
1 次查看(过去 30 天)
显示 更早的评论
Hi
I'm writing a function in MATLAB. In this function I call a Simulink diagram with following command: sim('diagram', 'vxin', value) The error I get is: block_diagram does not have a parameter named 'vxin'. In the diagram I have a constant block where I entered vxin. Clearly this isn't the right way.
How can I fix this?
Thanks
1 个评论
Santosh Gnanasekaran
2018-1-1
Probably 'vxin' is not in the base workspace as its value is undefined. you can assign any constant\variable in simulink pertaining to that particular block and then try again.
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Simulink Functions 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!