MATLAB Answers

How to make a Simulink block constant, execute only once?

조회 수: 50(최근 30일)
Luis Ruiz
Luis Ruiz 16 Aug 2018
답변: TAB 17 Aug 2018
I have a model in Simulink (2018a) which has more models inside. So I have:
parent.slx --> child.slx
I want child.slx to execute only once in the whole simulation, so basically its output will be constant at all times.

  댓글 수: 0

Sign in to comment.

채택된 답변

TAB
TAB 17 Aug 2018
Put your child model in Enabled Subsystem in parent model.
[parent.slx [Enabled Subsystem [Enchild.slx]]]
Enable the subsystem only once using "Stateflow" or using "Constant block + Unit delay Block arrangement".
Using "Constant block + Unit delay Block arrangement" you can do as below
[Constant(Value=0)]-->[Unit delay (Initial condition=1)]--> to enable port

  댓글 수: 0

Sign in to comment.

추가 답변(0개)

제품


릴리스

R2018a

Translated by