Plotting simulation results within GUI
1 次查看(过去 30 天)
显示 更早的评论
Hey there. I am faced with a problem and hope to get some advice on how to solve it in here. I am building a GUI with guide. Within this GUI I am running a SIMULINK simulation. I would like to automatically plot the simulation results afterwards. I do have all the scripts I need in order to do this manually without a GUI. Using the manual way everything runs fine. But when I try to achieve the same results within my GUI I do not get the variables (which should be saved within a struct) into the workspace of the callback routine from which I am running the simulation (I am using the sim-command to run the simulation). I tried to enable logging in the scope block, I used "to workspace" blocks and Outports but neither of the things I tried seem to work. When I am trying to write the results into a variable using results = sim('modelname') an empty variable is returned. So it seems to me that Simulink is writing to another workspace. Using the debugger, I was not able to find the results I was hoping to get in either of the gui workspaces.
Has anybody an idea on what my problem could be?
Thanks in advance
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 General Applications 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!