Chapter 6 Vectorized Code Generation
© National Instruments Corporation 6-13 AutoCode Reference
RT_FLOAT Brake;
RT_FLOAT Gear;
RT_FLOAT Clutch;
/***** Algorithmic Local Variables. *****/
RT_INTEGER i;
RT_INTEGER j;
RT_INTEGER k;
/******* Initialization. *******/
if (SUBSYS_PREINIT[1]) {
iinfo[0] = 0;
iinfo[1] = 1;
iinfo[2] = 1;
iinfo[3] = 1;
INIT = 1;
X = &ss_1_states[0];
XD = &ss_1_states[1];
{
RT_INTEGER ii;
for( ii=0;ii<5;ii++ ) {
X->sensor_delay[ii] = 0.0;
}
}
{
RT_INTEGER ii;
for( ii=0;ii<5;ii++ ) {
XD->sensor_delay[ii] = 0.0;
}
}
for( cnt=0;cnt<11;cnt++ ) {
R_P[cnt] = _R_P[cnt];
}
SUBSYS_PREINIT[1] = FALSE;
return;
}
/***** Output Update. *****/
/* ---------------------------- Time Delay */
/* {VecEx..12} */
if (INIT) {
k = 0;
for (i=1; i<=5; i++) {
X->sensor_delay[k] = R_P[i];