EasyLink
EasyLink is a C++ software development kit for developing blocks for SIMULINK (S-functions)
Quick reference

Input port methods

double input0=getInputScalar(0);
Array<double> input1=getInputArray<double>(1);

Output port methods

setOutputScalar(0,output0);
Array<double> output1=getOutputArray<double>(1);

Parameter port methods

int parameter0 = getParameterScalar(0);
double parameter1 = getParameterScalar(1);
std::string parameter2 = getParameterString(2);
Array<double> parameter3 = getParameterArray<double>(3);

Arrays

if (existMatlabArray("test")) ...
Array<double> test = newMatlabArray(2, 2, "test");
test(0, 0) = 2;
test(1, 1) = 4;
Array<double> test2 = getMatlabArray("test2");
test2 += 1;
test2.print();
Array<double> a(2, 2, "A");
a(0, 0) = -3;
a(1, 1) = 4;
a.print();

Copyright (c) 2014 FEMTO-ST / ENSMM / UFC / UTBM, Besançon, France. Generated by Doxygen.