Clear Filters
Clear Filters

Info

This question is closed. Reopen it to edit or answer.

Error when propagating variable length signal

1 view (last 30 days)
Andrew Poissant
Andrew Poissant on 9 Jul 2018
Closed: MATLAB Answer Bot on 20 Aug 2021
I have a simulink model that has an if action subsystem, and a matlab function block within that subsystem. The matlab function block outputs a variable of changing length, out1. The matrix size of out1 depends on sizes of other variables, which are not known until the if action subsystem block is activated during simulation. I declared out1 as variable size by calling coder.varsize('out1') in the matlab function block, and I specified the upper bound of the out1 and clicked the variable size check-box in the model explorer for out1. However, when I run the simulation I get the following error:
"The output signal sizes of block 'UAV_SIM_MAIN/GIHM1/Triggered Subsystem1/engine out/Gliding' depend on the input signal values. However, the subsystem that contains this block is set to 'Propagate sizes of variable-size signals only when enabling'. Consider placing this block outside subsystems with this parameter setting or changing the parameter 'Propagate sizes of variable-size signals' for 'UAV_SIM_MAIN/GIHM1/Triggered Subsystem1/engine out/Action Port' to 'During execution'."
How do I change the subsystem's parameter 'propagate sizes of variable-size signals' to 'during execution'? I can't take the Matlab function block outside of the subsystem like the error message suggests.

Answers (0)

This question is closed.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!