Vectorization Features - National Instruments AutoCode NI MATRIX Reference

National instruments ni matrixx reference manual
Table of Contents

Advertisement

Chapter 6
Vectorized Code Generation
k = k + 1;
}
}
k = 1;
for (i=1; i<=5; i++) {
Y->delayed_pulse[-1+i] = X->sensor_delay[-1+k];
k = k + 1;
}
/* ----------------------------
/* {VecEx..2} */
Throttle = -8.7*U->sensor_5;
Pedal = -7.6*U->sensor_11;
Brake = -6.5*U->sensor_12;
Gear = -5.4*U->sensor_4;
Clutch = -4.3*U->sensor_1;
/***** State Update. *****/
/* ----------------------------
/* {VecEx..12} */
k = 0;
XD->sensor_delay[k] = Throttle;
k = k + 1;
XD->sensor_delay[k] = Pedal;
k = k + 1;
XD->sensor_delay[k] = Brake;
k = k + 1;
XD->sensor_delay[k] = Gear;
k = k + 1;
XD->sensor_delay[k] = Clutch;
k = k + 1;
/***** Swap state pointers. *****/
XTMP = X;
X = XD;
XD = XTMP;
INIT = 0;

Vectorization Features

AutoCode Reference
This section describes features of the vectorized code. You do not have to
enable these features explicitly. These features are the natural result of
introducing arrays into the generated code. In other words, to support
vectorization for any model, these features must be present.
Gain Block */
Time Delay */
6-14
ni.com

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the AutoCode NI MATRIX and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Autocode ni matrixx

Table of Contents