Contenido principal

getFunctionCaller

Get AUTOSAR mapping information for Simulink function-caller block

Description

[arPortName,arOperationName,serverCallPoint] = getFunctionCaller(slMap,slFcnName) returns the value of the AUTOSAR client port arPortName and AUTOSAR operation arOperationName mapped to the Simulink® function caller block for Simulink function slFcnName.

example

Examples

collapse all

Get AUTOSAR mapping information for a function-caller block in a model in which AUTOSAR client function invocation is being modeled. The model has a function-caller block for Simulink® function readData.

hModel = "mControllerWithInterface_client";
open_system(hModel);
slMapC = autosar.api.getSimulinkMapping(hModel);
mapFunctionCaller(slMapC,"readData","cPort","readData");
[arPort,arOp,serverCallPoint] = getFunctionCaller(slMapC,"readData")
arPort = 
'cPort'
arOp = 
'readData'
serverCallPoint = 
'Synchronous'

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

Qualified function name, specified as a character vector or string scalar. The qualified function name is shown on the Function Caller block icon.

Example: "readData"

Example: "ClientPort.readData"

Output Arguments

collapse all

Variable that returns the name of the AUTOSAR client port mapped to the specified function-caller block.

Example: arPort

Variable that returns the name of the AUTOSAR operation mapped to the specified function-caller block.

Example: arOp

Server call point of function caller, returned as either Synchronous or Asynchronous.

Example: mapFunctionCaller(slMap,slFncName,arPortName,arOperationName,ServerCallPoint="Asynchronous")

Data Types: char | string

Version History

Introduced in R2014b