MATLAB: Accesing simulink data in Realtime

simulink

Hi ,
Does anybody know how one can access the Simulink data in realtime?
I need to access data coming out of a simulink block and use it as a limit in a completely different model. To Workspace does not serve the purpose as data gets collected there only after the simulation ends.
Any other way?

Best Answer

Use Model Reference to include your second model in the first one, and pass the signal of interest as an input to the second model.
HTH,
Arnaud