MATLAB Answers

Mehdi
0

Siumlink functionality (load_system) not supported by Compiler

Asked by Mehdi
on 31 May 2018
Latest activity Edited by TAB
on 31 May 2018
Hello,
I have made an executable using MATLAB compiler but it doesn't run properly. A part of my code runs a SIMULINK model programmatically using load_system and sim as shown here:
load_system('MySimModel')
set_param ('MySimModel', 'StartTime', num2str(ti), 'StopTime', num2str(tf))
options = simset('SrcWorkspace', 'current');
sim ('MySimModel', [], options)
Apparently load_system and sim are not supported by MATLAB Compiler. What's the workaround to resolve this issue? I have to use an executable file of my code on machines on which MATLAB is not installed. Thank you for your help.

  0 Comments

Sign in to comment.

1 Answer

Answer by TAB
on 31 May 2018
Edited by TAB
on 31 May 2018

Simulink models works only with Simulink engine which runs under Matlab.
Simulink is not provided with Matlab Runtime Environment. So simulink related functions won't work with your compiled Matlab code.

  0 Comments

Sign in to comment.