Main Content

Configure AUTOSAR Calibration Component

An AUTOSAR calibration parameter component (ParameterSwComponent) contains calibration parameters that can be accessed by AUTOSAR software components (SWCs) using an associated provider port. You can import a calibration component from ARXML code into Simulink® or use AUTOSAR.Parameter data objects to create a calibration component in Simulink.

To create a calibration component in Simulink, open the AUTOSAR parameters in your model and configure them for export in a calibration component. For example:

  1. Open a model configured for AUTOSAR that has AUTOSAR.Parameter data objects in the base workspace or data dictionary, or to which you can add AUTOSAR.Parameter data objects.

  2. Open an AUTOSAR parameter from the base workspace or data dictionary. In the AUTOSAR.Parameter dialog box, set Storage class to CalPrm. Use these attributes to configure the parameter for export in a calibration component:

    • HeaderFile — Optionally specify the name of the AUTOSAR software component header file that declares the calibration parameter.

    • ElementName, PortName, and InterfacePath — Associate the calibration parameter with a specific AUTOSAR element, AUTOSAR port, and AUTOSAR interface. Specify an element name, a port name, and an interface path.

    • CalibrationComponent — Qualified name of the calibration component to be exported, containing this parameter.

    • ProviderPortName — Short name of the provider port associated with the calibration component.

  3. Apply changes and save the model.

When you generate code from the model:

  • The software exports the calibration components specified for the AUTOSAR calibration parameters. For example, here is an excerpt of ParameterSwComponent XML exported based on the configuration of the calibration parameter K.

            <P-PORT-PROTOTYPE UUID="...">
                      <CONSTANT-REF DEST="CONSTANT-SPECIFICATION">/Company/Powertrain/
                  <PARAMETER-REF DEST="PARAMETER-DATA-PROTOTYPE">/CalibrationComponents/
  • Parameter initial values are exported on the ParameterProvideComSpec in the ParameterSwComponent and the ParameterRequireComSpec in the ApplicationSwComponent. Here is an excerpt of the exported ParameterRequireComSpec XML.

              <CONSTANT-REF DEST="CONSTANT-SPECIFICATION">/Company/Powertrain/DataTypes/
          <PARAMETER-REF DEST="PARAMETER-DATA-PROTOTYPE">/CalibrationComponents/counter_if/
      <REQUIRED-INTERFACE-TREF DEST="PARAMETER-INTERFACE">/CalibrationComponents/counter_if

For calibration component parameters, after you export your AUTOSAR components, you must include your calibration interface definition XML file to import the parameters into an authoring tool.


Use the CalPrm CSC attributes CalibrationComponent and ProviderPortName only to originate a calibration component in Simulink, not for a calibration component originated in an AUTOSAR authoring tool.

See Also