R2018a

New Features, Compatibility Considerations

AUTOSAR Release 4.3: Import and export AUTOSAR XML schema version 4.3

The software now supports AUTOSAR Release 4.3 (schema version 4.3.0) for import and export of arxml files and generation of AUTOSAR-compatible C code.

4.3 is now the default value for the model configuration parameter Generate XML file for schema version.

For more information, see Select an AUTOSAR Schema.

AUTOSAR Perspective: Map and configure software components by using Code Mapping Editor and AUTOSAR Dictionary

After you create an AUTOSAR software component model in Simulink, use the Code Mapping Editor and AUTOSAR Dictionary to further develop the AUTOSAR component. The Code Mapping Editor and AUTOSAR Dictionary provide mapping and property views of the component model, which can be used separately and together to configure the AUTOSAR component.

The Code Mapping Editor replaces the Simulink-AUTOSAR Mapping view of the Configure AUTOSAR Interface dialog box. The new dialog box provides in-canvas access to AUTOSAR mapping information, with a help panel, Property Inspector dialog box, batch editing, element filtering, easy navigation to model elements and AUTOSAR properties, and model element traceability. Use this view to map model elements to AUTOSAR component elements from a Simulink® model perspective.

The AUTOSAR Dictionary replaces the AUTOSAR Properties view of the Configure AUTOSAR Interface dialog box. Using a tree format, the new dialog box displays a mapped AUTOSAR component and its elements, communication interfaces, computation methods, and XML options. Use this view to configure AUTOSAR elements from an AUTOSAR component perspective.

AUTOSAR mapping and property functions are unchanged from previous releases. They allow you to get, set, add, and remove the mapping information and component properties displayed in the Code Mapping Editor and AUTOSAR Dictionary views of the AUTOSAR component model.

For more information, see AUTOSAR Component Configuration.

AUTOSAR XML Import and Export: Round-trip ComSpecs, import bitfield CompuMethods, export interface variation points, and automate more element creation

R2018a extends arxml import and export support for AUTOSAR ComSpecs, BITFIELD_TEXTTABLE CompuMethods, and variants, and automates creation of more elements during arxml imports and model updates.

Model ComSpecs for AUTOSAR sender and receiver data

In AUTOSAR software components, a sender or receiver port optionally can specify a communication specification (ComSpec). ComSpecs describe additional communication requirements for port data.

In R2018a, to model AUTOSAR sender and receiver ComSpecs in Simulink, you can:

  • Import sender and receiver ComSpecs

  • Create sender and receiver ComSpecs in Simulink

  • For nonqueued sender and receiver ports, modify ComSpec attribute InitValue

  • For nonqueued receiver ports, modify ComSpec attributes AliveTimeout and HandleNeverReceived

  • Export ComSpecs to arxml files

For more information, see Configure AUTOSAR Sender-Receiver Port ComSpecs.

Note

This support is available to R2017b Embedded Coder® customers by installing R2017b Embedded Coder Support Package for AUTOSAR Standard, Version 17.2.3 or later.

Import BITFIELD_TEXTTABLE CompuMethods

AUTOSAR CompuMethods of category BITFIELD_TEXTTABLE allow you to access bit values within an application data type of category VALUE. You can group bit values, assign labels to them, and define masks for accessing values within bytes of data.

In R2018a, you can import BITFIELD_TEXTTABLE CompuMethods from arxml files. After you import the CompuMethods, you can create Simulink enumerated types to represent bit groups and masks for accessing the bitfields, and reference them in Simulink bitwise and relational operator and constant blocks.

To create Simulink enumerated types for a BITFIELD_TEXTTABLE CompuMethod, call the AUTOSAR property function createEnumeration. The function creates a mask type and other enumerated types, based on what is defined in the specified CompuMethod. For example:

arProps = autosar.api.getAUTOSARProperties(modelName);
createEnumeration(arProps,'/Company/Module/CompuMethods/MyBitfieldCompuMethod');

Note

This support is available to R2016a, R2016b, R2017a, and R2017b Embedded Coder customers by installing the latest AUTOSAR support package for your release:

  • R2016a Embedded Coder Support Package for AUTOSAR Standard, Version 16.1.8 or later

  • R2016b Embedded Coder Support Package for AUTOSAR Standard, Version 16.2.5 or later

  • R2017a Embedded Coder Support Package for AUTOSAR Standard, Version 17.1.3 or later

  • R2017b Embedded Coder Support Package for AUTOSAR Standard, Version 17.2.3 or later

Export variation points for AUTOSAR interface variants

R2018a enhances AUTOSAR code generation support for variants.

  • If you model an AUTOSAR port with a variant condition in Simulink, arxml export now generates variation points on the AUTOSAR port and data accesses.

  • If you model an AUTOSAR runnable with a variant condition, arxml export now generates both a variation point and a corresponding variation point proxy for the runnable. The variation point and variation point proxy refer to the same AUTOSAR system constant.

Add Signal Invalidation blocks and ErrorStatus ports when required by imported AUTOSAR components

The AUTOSAR arxml importer now automatically adds Signal Invalidation blocks and ErrorStatus ports when required by an imported component that uses sender-receiver (S-R) communication. Importer function createComponentAsModel:

  • Adds a Signal Invalidation block connected to an outport if the outport is mapped to an AUTOSAR sender port and the associated S-R data element uses invalidation policy KEEP or REPLACE.

  • Adds an ErrorStatus port to a receiver component if the associated S-R data element meets at least one of these conditions:

    • Uses invalidation policy KEEP or REPLACE.

    • Uses an AliveTimeout value greater than 0.

    • Has HandleNeverReceived set to true.

Note

This support is available to R2017b Embedded Coder customers by installing R2017b Embedded Coder Support Package for AUTOSAR Standard, Version 17.2.1 or later.

Increased automation for AUTOSAR model updates

The arxml importer function updateModel now automates insertion and mapping of the following elements:

  • Inter-runnable variable (IRV) lines for AUTOSAR IRVs

  • Constant blocks for AUTOSAR parameters

  • Data store memory (DSM) blocks for AUTOSAR per-instance memory (PIM) blocks

Previously, these elements required manual additions to the model.

Model updates also now resize added Function Caller, Constant, and DSM blocks so that block text is readable.

Note

This support is available to R2016a, R2016b, R2017a, and R2017b Embedded Coder customers by installing the latest AUTOSAR support package for your release:

  • R2016a Embedded Coder Support Package for AUTOSAR Standard, Version 16.1.7 or later

  • R2016b Embedded Coder Support Package for AUTOSAR Standard, Version 16.2.4 or later

  • R2017a Embedded Coder Support Package for AUTOSAR Standard, Version 17.1.1 or later

  • R2017b Embedded Coder Support Package for AUTOSAR Standard, Version 17.2.0 or later

Navigate AUTOSAR Update Report using search bar

The update report generated by importer function updateModel now provides a search bar. You can quickly navigate to specific elements or other strings of interest.

For more information, see Import AUTOSAR Software Component Updates.

Note

This support is available to R2016a, R2016b, R2017a, and R2017b Embedded Coder customers by installing the latest AUTOSAR support package for your release:

  • R2016a Embedded Coder Support Package for AUTOSAR Standard, Version 16.1.8 or later

  • R2016b Embedded Coder Support Package for AUTOSAR Standard, Version 16.2.5 or later

  • R2017a Embedded Coder Support Package for AUTOSAR Standard, Version 17.1.3 or later

  • R2017b Embedded Coder Support Package for AUTOSAR Standard, Version 17.2.3 or later

Import reference definitions for AUTOSAR interface elements

The arxml importer function updateModel now imports reference definitions for AUTOSAR interface elements, such as SenderReceiverInterface. For a list of supported reference elements, see Import or Update Shared AUTOSAR Reference Element Definitions.

AUTOSAR Signal Invalidation Block: Specify invalidation policy and initial value directly as block parameters

Embedded Coder provides the Signal Invalidation block for modeling sender-receiver data invalidation in an AUTOSAR model. R2018a enhances signal invalidation modeling for simulation and code generation. You can now:

  • Specify Signal invalidation policy and Initial value for a data element directly as Signal Invalidation block parameters.

  • Correctly simulate the signal invalidation policy Replace for an invalidated signal. Previously, simulation would keep the last valid signal value rather than replace the input data value with an initial value.

  • Model the signal invalidation policy DontInvalidate for simulation and code generation.

For more information, see the Signal Invalidation block reference page.

AUTOSAR Basic Software: Use array and bus data types with NvMServiceCaller operations

When using the Basic Software block NvMServiceCaller to call ReadBlock, RestoreBlockDefaults, or WriteBlock operations, you now can specify array and bus data types. Use the block parameter Argument specification.

For more information, see the NvMServiceCaller block reference page.

Note

This support is available to R2016b, R2017a, and R2017b Embedded Coder customers by installing the latest AUTOSAR support package for your release:

  • R2016b Embedded Coder Support Package for AUTOSAR Standard, Version 16.2.5 or later

  • R2017a Embedded Coder Support Package for AUTOSAR Standard, Version 17.1.3 or later

  • R2017b Embedded Coder Support Package for AUTOSAR Standard, Version 17.2.3 or later

Obsolete AUTOSAR functions removed

R2018a ends support for some obsolete AUTOSAR functions.

  • You can no longer access the following obsolete arxml.importer functions. The functions have been removed from MATLAB® help.

    getApplicationComponentNamesGet AUTOSAR application software component names from arxml files
    getCalibrationComponentNamesGet AUTOSAR calibration component names from arxml files
    getClientServerInterfaceNamesGet AUTOSAR client-server interface names from arxml files
    getDependenciesGet AUTOSAR arxml dependency files
    getFileGet AUTOSAR arxml software component file
    getSensorActuatorComponentNamesGet AUTOSAR sensor/actuator software component names from arxml files
    setDependenciesSet AUTOSAR arxml dependency files
    setFileSet AUTOSAR arxml software component file
  • R2018a removes the XML option Default aliveTimeout from the XML options dialog box. Now you can set the AliveTimeout value for individual mapped AUTOSAR receiver ports, so the XML option is unnecessary. If you try to programmatically access the XML option DefaultAliveTimeout using AUTOSAR property function get or get, the software displays an error message.

  • In R2013b, a new programmatic interface for configuring AUTOSAR properties and mapping replaced the RTW.AutosarInterface class. R2018a ends support for models that use the RTW.AutosarInterface based mapping. These models are no longer automatically converted to use the new AUTOSAR properties and mapping approach. If you attempt an operation using the old mapping approach, the software displays an error message.

  • In R2013b, the autosar_ui_launch function replaced the autosar_gui_launch function, which was only briefly documented. R2018a removes autosar_gui_launch from the software.

Compatibility Considerations

If an AUTOSAR script or model relies on an obsolete AUTOSAR function, update it to use supported alternatives. For example:

  • AUTOSAR importer scripts can use the functions listed in the arxml.importer reference page in place of older functions such as getApplicationComponentNames and setFile. For example:

    • Use generic function getComponentNames with a component type argument instead of specialized functions getApplicationComponentNames, getCalibrationComponentNames, and getSensorActuatorComponentNames.

    • When importing arxml descriptions, specify multiple arxml file names instead of a single component file with dependency files.

  • AUTOSAR property scripts can set AliveTimeout values for individual mapped ports and elements, rather than setting the XML option DefaultAliveTimeout. For example:

    >> set(arProps,comSpecPath{1},'AliveTimeout',90)

    For more information, see Configure AUTOSAR Sender-Receiver Port ComSpecs.

  • AUTOSAR models that use pre-R2013b RTW.AutosarInterface based mapping should permanently migrate to using the AUTOSAR property and map functions listed in AUTOSAR Software Components and AUTOSAR Programmatic Interfaces. The new functions work with the component property and mapping information displayed in AUTOSAR Dictionary and the Code Mapping Editor.

    To automatically convert an AUTOSAR model to use the new AUTOSAR properties and mapping approach, open the model in a MATLAB release before R2018a. The software converts the model to use the new approach.

  • AUTOSAR scripts that call autosar_gui_launch must modify the function name to autosar_ui_launch. No change to function arguments is needed.

Cross-Release Code Integration: Import and simulate AUTOSAR code

Into the current release, import AUTOSAR component code that you generated in a previous release. Run software-in-the-loop (SIL) or processor-in-the-loop (PIL) simulations with the imported code. You can observe the interaction of code from a previous release with components implemented in the current release. For more information, see: