Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

To resolve issues starting MATLAB on Mac OS X 10.10 (Yosemite) visit: http://www.mathworks.com/matlabcentral/answers/159016

developing GUI using guide to interact with simulink model

Asked by sai vasavi on 7 Aug 2012

Hi, I developed one model in simulink.Now i want to display those output values and also some intermediate values in gui while the model is simulating.And also I have to acknowledge the user if some functions are executing in simulink model like "so and so function is called and it is executing". Please can anyone help in doing the same.Please let me know if the question is not clear. Thanks in advance

0 Comments

sai vasavi

Products

2 Answers

Answer by Kaustubha Govind on 8 Aug 2012
Accepted answer

You may want to follow the documentation for Accessing Block Data During Simulation for information on accessing block outputs during simulation.

4 Comments

Kaustubha Govind on 24 Aug 2012

You don't need to use S-functions. You can just follow the directions in the documentation that I linked. In fact there was another thread recently where the user was able to achieve a GUI update without using S-functions: http://www.mathworks.com/matlabcentral/answers/46363-reading-a-wire-value-from-simulink-into-the-command-window-or-guide

Craig on 24 Sep 2012

my understanding is unless you use s functions you'll be restricted to viewing signals about standard Simulink blocks.

Kaustubha Govind on 24 Sep 2012

Craig: Not sure what you mean by "you'll be restricted to viewing signals about standard Simulink blocks" - what exactly are you attempting to view then?

Kaustubha Govind
Answer by Babak on 7 Aug 2012

You can trigger the GUI with its name (whatever name you saved it with) as long as the GUI's m-file and figure are in MATLAB path.

So

First, add the path of the m-file and figure fo the GUI to MATLAB's path if the GUI is not in your "current folder"

Second: to trigger the GUI, you can add a MATLAB Fcn block or any other Simulink block that you can write a piece of script in it...Another way is to develop an S-function which can be done with S-function builder.

1 Comment

sai vasavi on 8 Aug 2012

Hi Babak Thanks for your quick response.I am unable to understand your answer clearly.Please can you elaborate your answer.

Babak

Contact us