AUTOSAR XML Options Settings
AUTOSAR software component XML Options
The autosar.api.getAUTOSARProperties
function returns an object representing elements
and properties in the AUTOSAR Dictionary. You can then use the get
and set
functions to view and change these
settings. For an example configuring these options using the AUTOSAR Dictionary, see Configure AUTOSAR XML Options.
openExample("autosar_swc"); hModel = "autosar_swc"; arProps = autosar.api.getAUTOSARProperties(hModel); set(arProps,"XmlOptions","ArxmlFilePackaging","SingleFile"); get(arProps,"XmlOptions","ArxmlFilePackaging")
ans = 'SingleFile'
View and Edit XML Options
XML Options Source
— Source of XML options
Inlined
(default) | Inherit from AUTOSAR architecture model
Source of XML options to use when the model builds if a component model is contained within an AUTOSAR architecture model, specified as one of these values:
Inlined
— Override the shared settings to the XML option settings of the local component model.Inherit from AUTOSAR architecture model
— Use the shared architecture model XML option settings.
Programmatic Use
Parameter:
XmlOptionsSource |
Type: string scalar | character vector |
Values:
"Inlined" | "Inherit" |
Default:
"Inlined" |
Exported XML File Packaging
— Packaging type for ARXML file export
Modular
(default) | SingleFile
Packaging type of exported ARXML files, specified as one of these values:
Modular
— Generate individual ARXML files containing component, datatype, implementation, interface, and timing information.SingleFile
— Generate a single ARXML file.
Programmatic Use
Parameter:
ArxmlFilePackaging |
Type: string scalar | character vector |
Values:
"Modular" | "SingleFile" |
Default:
"Modular" |
Package Paths
Datatype Package
— Data types package path
character vector | string scalar
Absolute path of the data types package.
Note
The DataTypePackage
path and
ApplicationDataTypePackage
path must be different.
Example: /Company/Powertrain/DataTypes
Programmatic Use
Parameter:
DataTypePackage |
Type: string scalar | character vector |
Default:
'' |
Interface Package
— Interface package path
character vector | string scalar
Absolute path of the interface package.
Example: /Company/Powertrain/Interfaces
Programmatic Use
Parameter:
InterfacePackage |
Type: string scalar | character vector |
Default:
'' |
AUTOSAR Platform Types
Implementation Platform Types Package
— Implementation platform data type package path
character vector | string scalar
The top-level package name for AUTOSAR implementation platform types and base types.
Programmatic Use
Parameter:
PlatformDataTypePackage |
Type: string scalar | character vector |
Default:
'' |
User-defined ImplementationDataType References
— Implementation data type reference behavior
BaseTypeReference
(default) | PlatformTypeReference
Implement data type reference behavior, specified as one of these values:
BaseTypeReference
— User-defined implementation data types reference an SW base type (CATEGORY
is set toVALUE
in the ARXML file).PlatformTypeReference
— User-defined implementation data types reference an AUTOSAR implementation data type (CATEGORY
is set toTYPE_REFERENCE
in the ARXML file).
Programmatic Use
Parameter:
UsePlatformTypeReferences |
Type: string scalar | character vector |
Values:
"BaseTypeReference" | "PlatformTypeReference" |
Default:
"BaseTypeReference" |
Note
This option is only available for the AUTOSAR Classic Platform.
Native Declaration
— Native declaration property
PlatformTypeName
(default) | CIntegralTypeName
Property that controls whether the native declaration inherits the AUTOSAR platform type name or uses a C integral type name, specified as one of these values:
PlatformTypeName
— The native declaration inherits the AUTOSAR platform type name.CIntegralTypeName
— The native declaration uses a C integral type name according to the hardware configuration specified in the model settings.
Programmatic Use
Parameter:
NativeDeclaration |
Type: string scalar | character vector |
Values:
"PlatformTypeName" | "CIntegralTypeName" |
Default:
"PlatformTypeName" |
Note
This option is available only for the AUTOSAR Classic Platform.
Platform Type Names
— Schema for AUTOSAR data types
AUTOSAR4.x
(default) | AUTOSAR3.x
Schema for AUTOSAR data types, specified as one of these values:
AUTOSAR3.x
— uses the AUTOSAR platform types AUTOSAR 3.x.AUTOSAR4.x
— uses the AUTOSAR platform types AUTOSAR 4.x.
To learn more about AUTOSAR platform types and their corresponding Simulink® data types, see About AUTOSAR Data Types.
Programmatic Use
Parameter:
PlatformTypeNames |
Type: string scalar | character vector |
Values:
"AUTOSAR3.x" | "AUTOSAR4.x" |
Default:
"AUTOSAR4.x |
Note
This option is available only for the AUTOSAR Classic Platform.
Additional Packages
ApplicationDataType Package
— Application data type package path
character vector | string scalar
Absolute path of the application data type package.
Note
The DataTypePackage
path and
ApplicationDataTypePackage
path must be different.
Example:
/Company/Powertrain/ApplDataTypes
Programmatic Use
Parameter:
ApplicationDataTypePackage |
Type: string scalar | character vector |
Default:
'' |
SwBaseType Package
— SwBaseType
package path
character vector | string scalar
Absolute path of the SwBaseType
package.
Example: /Company/Powertrain/SwBaseTypes
Programmatic Use
Parameter:
SwBaseTypePackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
DataTypeMappingSet Package
— Data type mappings package path
character vector | string scalar
Absolute path of the data type mappings package.
Example: /Company/Powertrain/DataTypeMappings
Programmatic Use
Parameter:
DataTypeMappingPackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
ConstantSpecification Package
— Constant specification package path
character vector | string scalar
Absolute path of the constant specification package.
Example: /Company/Powertrain/Constants
Programmatic Use
Parameter:
ConstantSpecifcationPackage |
Type: string scalar | character vector |
Default:
'' |
Physical DataConstraints Package
— Data constraint package path
character vector | string scalar
Absolute path of the data constraint package.
Example: /Company/Powertrain/DataConstrs
Programmatic Use
Parameter:
DataConstraintPackage |
Type: string scalar | character vector |
Default:
'' |
SystemConstant Package
— System-level constant values package path
character vector | string scalar
Absolute path of the system-level constant values package.
Example: /Company/Powertrain/SystemConstants
Programmatic Use
Parameter:
SystemConstantPackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
PostBuildVariantCriterion Package
— PostBuildVariantCriterions
package path
character vector | string scalar
Absolute path of the PostBuildVariantCriterions
package.
Example: /Company/Powertrain/DataTypes/PostBuildCriterions
Programmatic Use
Parameter:
PostBuildVariantCriterionPackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
SwAddressMethod Package
— SwAddressMethod
package path
character vector | string scalar
Absolute path of the SwAddressMethod
package.
Example: /DataTypes/SwAddrMethods
Programmatic Use
Parameter:
SwAddressMethodPackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
ModeDeclarationGroup Package
— Mode declaration group package path
character vector | string scalar
Absolute path of the mode declaration group package.
Example: /Company/Powertrain/ModeDeclarations
Programmatic Use
Parameter:
ModeDeclarationGroupPackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
CompuMethod Package
— CompuMethod
package path
character vector | string scalar
Absolute path of the CompuMethod
package.
Example: /Company/Powertrain/CompuMethods
Programmatic Use
Parameter:
CompuMethodPackage |
Type: string scalar | character vector |
Default:
'' |
Note
This option is available only for the AUTOSAR Classic Platform.
Unit Package
— Unit package path
character vector | string scalar
Absolute path of the unit package.
Example: /Company/Powertrain/Units
Programmatic Use
Parameter:
UnitPackage |
Type: string scalar | character vector |
Default:
'' |
SwRecordLayout Package
— SwRecordLayout
package path
character vector | string scalar
Absolute path of the SwRecordLayout
package.
Example: /Company/Powertrain/ApplDataTypes/SwRecordLayouts
Programmatic Use
Parameter:
SwRecordLayoutPackage |
Type: string scalar | character vector |
Default:
'' |
Internal DataConstraints Package
— Internal data constraints package path
character vector | string scalar
Absolute path of the internal data constraints package.
Example: /Company/Powertrain/DataTypes/DataConstrs
Programmatic Use
Parameter:
InternalDataConstraintPackage |
Type: string scalar | character vector |
Default:
'' |
Additional Options
ImplementationDataType References
— Control AUTOSAR data type generation
Allowed
(default) | NotAllowed
Setting for generating AUTOSAR data types, specified as one of these values.
Allowed
— Allow direct reference of implementation types in the generated ARXML code. If an application data type is not strictly required to describe an AUTOSAR data type, use an implementation data type reference.NotAllowed
— Do not allow direct reference of implementation data types in the generated ARXML code. Generate an application data type for each AUTOSAR data type.
By default, Simulink generates application base types only for fixed-point data types and enumerated data types with storage types. You can override the default behavior for generating application types by configuring the ARXML exporter to generate an application type, along with the implementation type and base type, for each exported AUTOSAR data type.
Programmatic Use
Parameter:
ImplementationTypeReference |
Type: string scalar | character vector |
Values:
"Allowed" | "NotAllowed" |
Default:
"Allowed" |
SwCalibrationAccess Default Value
— Default accessibility of data elements
ReadWrite
(default) | ReadOnly
| NotAccessible
The default accessibility for measurement variables, calibration parameters, and signal and parameter data objects, specified as one of these values:
ReadOnly
— Data element appears in the generated description file with read-only access.ReadWrite
— Data element appears in the generated description file with both read and write access.NotAccessible
— Data element appears in the generated description file and is not accessible using calibration and measurement tools.
Programmatic Use
Parameter:
SwCalibrationAccessDefault |
Type: string scalar | character vector |
Values:
"ReadWrite" | "ReadOnly" | "NotAccessible" |
Default:
"ReadWrite" |
CompuMethodDirection
— Direction of CompuMethod
conversion
InternalToPhys
(default) | PhysToInternal
| Bidirectional
Direction of the CompuMethod
conversion, specified as one of
these values.
InternalToPhys
— GenerateCompuMethod
sections for conversion of internal values to their physical representations.PhysToInternal
— GenerateCompuMethod
sections for conversion of physical values to their internal representations.Bidirectional
— GenerateCompuMethod
sections for both internal-to-physical and physical-to-internal conversion directions.
Programmatic Use
Parameter:
CompuMethodDirection |
Type: string scalar | character vector |
Values:
"InternalToPhys" | "PhysToInternal" | "Bidirectional" |
Default:
"InternalToPhys" |
Note
This option is available only for the AUTOSAR Classic Platform.
Internal DataConstraints Export
— Export setting for internal data constraints
false
(default) | true
Export setting for internal data constraints, specified as true
or false
, and returned as logical 1
or
0
.
true
— Enable export of internal data constraints.false
— Disable export of internal data constraints.
Programmatic Use
Parameter:
InternalDataConstraintExport |
Type: logical |
Default:
false |
Note
This option is available only for the AUTOSAR Classic Platform.
Export Lookup Table Application Value Specification
— Export setting for lookup table constants
true
(default) | false
Export setting for lookup table constants, specified as true
or
false
, and returned as logical 1
or
0
.
true
— Enable export of lookup table constants.false
— Disable export of lookup table constants.
Programmatic Use
Parameter:
ExportLookupTableApplicationValueSpecification |
Type: logical |
Values:
true | false |
Default:
true |
Note
This option is available only for the AUTOSAR Classic Platform.
VariationPoint Binding Time Override
— Binding time override for variation points
PreCompileTime
(default) | CodeGenerationTime
Binding time override for variation points, excluding variation point proxies, implementation data types, and application data types, specified as one of the following values:
PreCompileTime
— Set the binding time for variation points to before compile time.CodeGenerationTime
— Set the binding time for variation points to be at code generation.
Programmatic Use
Parameter:
VpBindingTimeOverride |
Type: string scalar | character vector |
Values:
"PreCompileTime" | "CodeGenerationTime" |
Default:
"PreCompileTime" |
Programmatic Options
CanBeInvokedConcurrentlyDiagnostic
— Produce error or warning
"Error"
(default) | "Warning"
Setting to produce an error or warning when generating code for a model that cannot be invoked concurrently, specified as one of these values:
"Error"
— Produce an error."Warning"
— Produce a warning.
Example: "Warning"
Data Types: char
| string
ComponentQualifiedName
— Name of component
''
(default) | character vector | string scalar
Absolute path of the component name, specified as a character vector or string scalar.
Example:
'/Company/Powertrain/Components/ASWC'
Data Types: char
| string
ExportPropagatedVariantConditions
— Export setting for propagated variant conditions
"All"
(default) | "None"
Export setting for propagated variant conditions, specified as
"All"
or "None"
.
"All"
— The propagated variant conditions are exported."None"
— The propagated variant conditions are not exported.
Example: "None"
Data Types: char
| string
ExportSwRecordLayoutAnnotationsOnAdminData
— Export setting for AdminData
in ARXML lookup table descriptions
false
(default) | true
Export setting for AdminData
in the ARXML lookup table
description, specified as true
or false
, and
returned as 1
or 0
.
true
— Enable export ofAdminData
.false
— Disable export ofAdminData
.
Example: true
Note
This option is available only for the AUTOSAR Classic Platform.
Data Types: logical
ImplementationQualifiedName
— Name of software component implementations
''
(default) | character vector | string scalar
Absolute path of software component implementations, specified as a character vector or string scalar.
Example: '/Company/Powertrain/SwcImplementations/ASWC_Impl'
Note
This option is available only for the AUTOSAR Classic Platform.
Data Types: char
| string
InternalBehaviorQualifiedName
— Internal behavior qualified name
''
(default) | character vector | string scalar
Absolute path of the atomic software component internal behavior qualified name, specified as a character vector or string scalar.
Example: '/Company/Powertain/Components/ASWC_IB'
Note
This option is available only for the AUTOSAR Classic Platform.
Data Types: char
| string
MoveElements
— Modify a package path
"All"
(default) | "None"
| "Alert"
If you programmatically modify a package path, you can specify the handling of
affected elements by setting MoveElements
to one of these values:
"All"
— All affected package elements will be moved to the modified package path."Alert"
— If packageable elements are affected, a dialog box with OK and Cancel buttons appears. Clicking OK moves the affected package elements to the modified package path. Clicking Cancel sets the new package path without moving any package elements."None"
— None of the affected package elements will be moved to the modified package path.
Example: "Alert"
Data Types: char
| string
Network Binding
— Network Binding
"DDS"
(default) | "SOME/IP"
Network binding option through which the AUTOSAR adaptive applications communicate
with each other, specified as "DDS"
or
"SOME/IP"
.
Example: 'SOME/IP'
Note
This option is available only for the AUTOSAR Adaptive Platform.
Data Types: char
| string
TimingPackage
— Timing package path
''
(default) | character vector | string scalar
Absolute path of the timing package, specified as a character vector or string scalar.
Example: '/Timing'
Note
This option is available only for the AUTOSAR Classic Platform.
Data Types: char
| string
Version History
Introduced in R2013b