Main Content

removeSignal

Remove万博1manbetxblock signal from AUTOSAR mapping

Description

example

removeSignal(slMap,slPortHandle)removes the Simulink®block signal associated with outport port handleslPortHandlefrom AUTOSAR mapping.

Examples

collapse all

In example modelautosar_swc_counter, remove Simulink signalequal_to_count, which originates in theRelOptblock, from the AUTOSAR component signal mapping.

hModel ='autosar_swc_counter'; addpath(fullfile(matlabroot,'/examples/autosarblockset/main')); open_system(hModel); slMap = autosar.api.getSimulinkMapping(hModel); portHandles = get_param('autosar_swc_counter/RelOpt','portHandles'); outportHandle = portHandles.Outport; removeSignal(slMap,outportHandle);

Input Arguments

collapse all

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

Example:slMap

Outport port handle for a Simulink block signal to remove from AUTOSAR mapping. Use MATLAB®commands to construct the outport port handle. For example, for a Relational Operator block namedRelOpt:

portHandles = get_param('autosar_swc_counter/RelOpt','portHandles'); outportHandle = portHandles.Outport;

Example:outportHandle

版本历史

Introduced in R2020b