5.1.65. Non-volatile adaptive 1-d map look-up (pnv_AdaptiveMap1d)

Adaptive 1-d map look-up and interpolation.

5.1.65.1. Supported targets

All targets

5.1.65.2. Required license

None (Main library). (See Section 2.3, “Licensed Features”.)

5.1.65.3. Description

Looks up the inport x in the X-axis Data (default) parameter, interpolates the corresponding elements in the Adaptive Z Data (default) parameter, giving a corresponding adapted_z as the output.

The adaptive 1-d look-up block is similar to the OpenECU put_Calmap1d block, except that the z-axis look-up values can change over time under control of the model and be recovered from non-volatile memory when the model starts. If the adaptive values cannot be recovered at start-up, or if the model is simulated, the default values are used before any adaption takes place.

The target non-volatile memory is provided in two ways: either through storage that requires an external power source when the ECU is powered down (battery backed RAM storage), or not (Flash storage). See the technical specification for details on which storage type is supported by each target.

The battery backed non-volatile memory requires a small amount of power overall, i.e., much less than powering the ECU normally.

The adaptive data is check-summed using a 16-bit CRC. Failure to match the check-sum against the adaptive data on start-up means that the data cannot be recovered. In this case, or if the model is simulated, adaptive data is reverted to the default value specified when the model was built.

Warning

Unlike R12 Simulink maps, 1-d and 2-d maps in OpenECU do not extrapolate beyond the limits of the input axis or axes. OpenECU calibration maps should be used for all maps that form part of an OpenECU build.

Some calibration tools provide a feature which shows the map in graphical or tabular form together with the active interpolation point. OpenECU supports this feature by populating the ASAP2 file with the signal name which corresponds to the x inport. To make this feature work, the x signal must be a named DD entity with its storage class property set to ExportedGlobal.

5.1.65.4. Inports

  • x

    The x-value at which a z-value is to be adapted then interpolated. May be a scalar or a vector. If the inport is attached to a vector, the size of the vector must match the size of any vector attached to another inport.

    Value type:Real
    Calibratable:No
  • adapt_increment

    The increment to the current adapted value. The increment is only used when the inports adapt and reset are conditioned correctly. May be a scalar or a vector. If the inport is attached to a vector, the size of the vector must match the size of any vector attached to another inport.

    Value type:Real
    Calibratable:No
  • adapt

    1 if the current adapted value should be adjusted, 0 otherwise. If the inport reset is 1, no adaption will occur (even if inport adapt is 1). May be a scalar or a vector. If the inport is attached to a vector, the size of the vector must match the size of any vector attached to another inport.

    Range: 0 or 1

    Value type:Boolean
    Calibratable:No
  • reset

    1 if the current adapted value should be reset to Adaptive Z Data (default), 0 otherwise. May be a scalar or a vector. If the inport is attached to a vector, the size of the vector must match the size of any vector attached to another inport.

    Range: 0 or 1

    Value type:Boolean
    Calibratable:No

5.1.65.5. Outports

  • adapted_z

    The adapted value or values interpolated from parameter Adaptive Z Data (default) at the value or values for inport x.

    Value type:Real
    Calibratable:No

5.1.65.6. Mask parameters

  • X-axis Data (default)

    The name of the map's x axis (e.g. vftm_mymap_x, see Section "Naming rules"). There must be two or more elements in this parameter and that must be the same as the number of elements in parameter Adaptive Z Data (default). The values of this parameter must increase monotonically and adjacent values must not be the same.

    Value type:Real
    Calibratable:Yes, offline and online
  • Adaptive Z Data (default)

    The name of the map's z axis (e.g. vftm_mymap_zsee Section "Naming rules"). There must be two or more elements in this parameter and that must be the same as the number of elements in X-axis Data (default). The adaptive block reverts to these values when the reset inport is asserted or when the block data is unrecoverable during power initialisation of the ECU.

    Value type:Real
    Calibratable:Yes, offline and online
  • Sample time

    The periodicity of the block execution.

    Range: [0.001, 3600] seconds

    Value type:Real
    Calibratable:No

5.1.65.7. Notes

  • The build process generates a corresponding ASAP2 entry to the adaptive parameter that can be accessed via a calibration tool. The name of this entry has a fifth character 'a', i.e., given the default parameter name vtfm_mymap_z, an ASAP2 entry with name vtfma_mymap_z is generated. Note that this implies that only a single adaptive parameter can exist per named default parameter.

    Warning

    If two or more blocks refer to the same named item in the Adaptive Z Data (default) field, these blocks will independently adapt the same adaptive parameter.

    The reset, adaption, look-up and interpolation work as follows:

    Possible reset

    If the inport reset is 1, the block reverts the Adaptive Z Data (default) parameter data to the block's defaults and sets the output from a look-up and interpolation.

    Possible adaption

    If a reset has not occurred and the inport adapt is 1, then the Adaptive Z Data (default) parameter data is altered as follows before setting the output from a look-up and interpolation.

    xa and xb bound inport x (see exceptions below), za and zb are the corresponding elements of the parameter Adaptive Z Data (default).

    When the software adapts the 1-d look-up table, the Adaptive Z Data (default) is modified as follows:

    If the inport x is less than xa and xa is the first element in the X-axis Data (default) parameter then the software treats xb as the same element as xa, zb as the same element as za and performs the adaption calculation with interpl as 0.

    If the inport x is greater than xb and xb is the last element in the X-axis Data (default) parameter then the software treats xa as the same element as xb, za as the same element as zb and performs the adaption calculations with interpl as 1.

    Look-up and interpolation

    Works as the put_Calmap1d block.