Hello guys,
I’m trying to setup a matlab script that automatically load, run and stop the CM4S simulation.
After reading the ProgrammersGuide, i think that all can be done with the following few line of code:
%% Init Simulation
disp(['Load TestRun: ’ TestRunName]);
cmguicmd(['LoadTestRun ’ TestRunName]);
%% Start Sim
disp(‘Start Sim…’);
cmguicmd(‘StartSim’);
disp(‘Waiting…’);
cmguicmd(‘WaitForCondition {$Qu(Time) > 50}’);
disp(‘Sim end. Load data…’);
The problem is that the script get stuck at ‘WaitForCondition’ command. From the CM GUI i see that the SIM status is blocked at ‘Preparation’.
Any suggestion?