Call MATLAB

Commands:

.MATLAB.init %% activate MATLAB engine .MATLAB.deinit %% close MATLAB engine .MATLAB.exec(<string>) %% execute MATLAB line .MATLAB.get(<string>) %% get variable from MATLAB .exp.MATLAB %% bring current experiment to MATLAB as a variable X in TDMS format .pulse.command.pattern.MATLAB='MATLAB script' %% execute script and bring variable p as a shape

Example:

.MATLAB.init %% activate MATLAB engine .MATLAB.exec('a=6') %% execute MATLAB line .MATLAB.get('a') %% get variable from MATLAB .MATLAB.deinit %% close MATLAB engine .puls.awg.shape.MATLAB='px=transpose(linspace(0,pi,100)); p=[sin(px),cos(px)];'