Data Dictionary Rules

NOTE: these rules apply to text based data dictionaries. If using the Simulink data dictionary file (.sldd) with Matlab R2015a or later, see Simulink Data Dictionary.


File and Directory Structure


Naming Rules

OpenECU uses a naming convention for data dictionary entries in order to determine data types for the generated code, and for use with development tools. Only the required items are described below.

Rules for DD Names:

Prefix

The Naming Rules describe some recommended conventions. Most of these are optional, the only required convention is that the 4th character of the name indicates the data type. For example, the following are all valid names for a calibration scalar: xyzc_variable_name_units, XYZc_VariableName_units, XYZc_units_VariableName.

Suffix

For maps or lookup tables, the last character indicates which axis the data belongs to.


DD Entry Properties

Values:

NOTE: value will be set to zero if not specified, so MATLAB workspace will have a value.

Description:

Type:

Min / Max:

Enums (Enumerations)


Example

Name           Value               Units  Type    Min Max  Description

** Example of a signal DDE
moi_pressure                       kPa    real_T  20  80   Example of a named signal

** Example of a constant look-up DDE
moic_constant  50                  kPa    real_T  20  80   Example of a calibration constant

** Example of set of a 1D table/map look-up DDEs
moim_1d_map_x  [20 40 80]          kPa    real_T  20  80   Example of a x-axis for a 1d map
moim_1d_map_z  [0  0  1]           state  bool    0   1    Example of a z-data for a 1d map

** Example of set of a 2D table/map look-up DDEs
moim_2d_map_x  [20 40]             kPa    real_T  20  80   Example of a x-axis for a 2d map
moim_2d_map_y  [1  5  10]          sec    real_T  0   25   Example of a y-axis for a 2d map
moim_2d_map_z  [0  1; 4  5; 8  9]  steps  real_T  0   100  Example of a z-data for a 2d map

** Example of set of an array DDE
moiv           [1 2 3 5 8 13]      counts real_T  0   100  Example of an array


More Information

      Copyright © 2016 Pi Innovo, All rights reserved