
20
supported by TargetLink: the user can either generate a separate structure for
every parameter set or generate an array of structures containing all instances.
Those structures can have as many parameters as the memory allows and no
limitation is set for how large the structures can be. The following example shows
three parameters and two parameter sets in two separate structures:
In the generated code the parameter sets are accessed by a pointer which refers to
the selected parameter set structure. The following code example shows how the
parameter set structures are used in the generated code:
It is a simple task for the user of TargetLink to make a parameter calibratable. The
right class should be chosen for the calibratable parameter in question. TargetLink
has predefined classes that make variable calibration possible. The variables are
written into a ASAM-MCD 2MC file. ASAM-MCD 2MC, formerly known as
ASAP2, is a commonly used standard for describing ECU-internal data. The
standard was developed by ASAM e.V. which stands for Association for
Standardization of Automation and Measuring Systems e.V. ASAM-MCD 2MC
files contain the information required by an MC system to access an ECU for
parameter calibration.
Vca DV tp Vca DVA =
5
3
1
}; /* for data variant item A */
Vca_DV_tp Vca_DVB = {
6
9
1
}; /* for data variant item B */
switch(varID)
case 1: {
pVca_DV = &Vca_DVA;
break;
}
case 2: {
pVca_DV = &Vca_DVB;
break;
}
default: {
pVca_DV = &Vca_DVA;
break;
}
}
Commenti su questo manuale