MATLAB Answers

Simulink: Obtaining propagated signal names programmatically

49 views (last 30 days)
sst on 12 Dec 2011
Commented: Lukas on 13 Aug 2019
Hi, I am trying to obtain the propagated signal name for a signal programmatically. For example:
porthandles = get(gcbh, 'PortHandles');
linehandle = get(porthandles.Outport(1), 'Line');
%Assume that the SignalPropagation property is turned off
%As soon as the command below is executed, the name '<PropagatedName>' appears
%on the line in the Simulink model
set(linehandle, 'SignalPropagation', 'all');
Now, is there a property associated with linehandle that lets us obtain this propagated signal name? The 'Name' property returns an empty string.


Sign in to comment.

Accepted Answer

Fangjun Jiang
Fangjun Jiang on 14 Dec 2011


vaibhav hosur
vaibhav hosur on 22 Jan 2016
Can we check whether the propogation is above the line or below the line?
Lukas on 13 Aug 2019
This worked for me:
porthandles = get(gcbh, 'PortHandles');
for ip = 1:numel(porthandles.Inport)
linehandle = get(porthandles.Inport(ip), 'Line');
srchandle = get(linehandle,'SrcPortHandle');

Sign in to comment.

More Answers (0)

Sign in to answer this question.