I am attempting to save Simulation Data Inspector (SDI) data onto a MAT file programmatically. I use the following command to start simulation using a script:
set_param(gcs,'SimulationCommand','start');
In subsequent lines of the script, the run objects are generated, and the signals plotted in SDI are saved using:
Simulink.sdi.save('<filename>.mat');
This saves incomplete, or no signals on the MAT-file. However, when I save the plots from the GUI of the SDI, it works well. What could be the issue while saving programmatically?
Best Answer