Main Content

getInport

Get AUTOSAR mapping information for Simulink inport

Description

example

[arPortName,arDataElementName,arDataAccessMode] = getInport(slMap,slPortName) returns the values of the AUTOSAR port arPortName, AUTOSAR data element arDataElementName, and AUTOSAR data access mode arDataAccessMode mapped to Simulink® inport slPortName.

Examples

collapse all

Get AUTOSAR mapping information for a model inport in the example model autosar_swc_expfcns. The model has an inport named RPort_DE1.

hModel = 'autosar_swc_expfcns';
addpath(fullfile(matlabroot,'/examples/autosarblockset/main'));
open_system(hModel);
slMap=autosar.api.getSimulinkMapping(hModel);
[arPortName,arDataElementName,arDataAccessMode]=getInport(slMap,'RPort_DE1')
arPortName =
RPort

arDataElementName =
DE1

arDataAccessMode =
ImplicitReceive

Input Arguments

collapse all

Simulink to AUTOSAR mapping information for a model, previously returned by slMap = autosar.api.getSimulinkMapping(model). model is a handle, character vector, or string scalar representing the model name.

Example: slMap

Name of the model inport for which to return AUTOSAR mapping information.

Example: 'Input'

Output Arguments

collapse all

Variable that returns the name of the AUTOSAR port mapped to the specified Simulink inport.

Example: arPortName

Variable that returns the name of the AUTOSAR data element mapped to the specified Simulink inport.

Example: arDataElementName

Variable that returns the value of the AUTOSAR data access mode mapped to the specified Simulink inport. The value can be ImplicitReceive, ExplicitReceive, QueuedExplicitReceive, ErrorStatus, ModeReceive, IsUpdated, EndToEndRead, or ExplicitReceiveByVal

Example: arDataAccessMode

Introduced in R2013b