Importing workspace variable to simulink?
2 次查看(过去 30 天)
显示 更早的评论
Can u help how to import a workspace variable to simulink. I am facing problem with simin block. It is asking for time column. But i want to send only variable, in my case it is row vector.
0 个评论
回答(1 个)
Fangjun Jiang
2020-8-6
Use "From Workspace" block. Assume your data is MyData=1:10, you need to make it a column vector and also provide a column vector of time.
time=(0:0.1:0.9)';
Specify the data as [time, MyData.'] for the "From Workspace" block.
2 个评论
Santos García Rosado
2021-3-10
Link to Fangjun's answer: https://www.mathworks.com/matlabcentral/answers/768262-import-matlab-matrix-to-simulink
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Interactive Model Editing 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!