MATLAB Answers

Using triggered subsystem with either - need a reset but how?

5 ビュー (過去 30 日間)
s0ter48
s0ter48 2019 年 10 月 29 日
Commented: s0ter48 2019 年 11 月 18 日
Hey guys,
I need to use a triggered subystem to detect flanks (pos and neg) and calculate the time difference between these and then pass the value on to calculate the speed which will go into a PI controller and herefore i need also the the values (in my case it will be 0 - when no more flanks are detected) when the system is not triggered anymore.
But my problem is that the triggered subsystem starts when the flanks starts and hold the last value when no flanks are coming anymore.
I need the 0 at the beginning and the 0 at the end because with this i would pass on a wrong value to the controller.
2019-10-28_17-01-32.png
I build an example so u can understand what I mean.
Thanks in advance. =)

  0 件のコメント

サインイン to comment.

件の回答 (2)

s0ter48
s0ter48 2019 年 11 月 1 日
Hmm... nobody can help me with this?

  0 件のコメント

サインイン to comment.


Ganesh Regoti
Ganesh Regoti 2019 年 11 月 6 日
Hi,
There is no such feature of resetting the block states in triggered subsystem. It is also stated in the documentation here.
Instead you can use Enabled Subsystem block if it suits your model as it has the resetting of states option. You can refer the following link
Hope this helps!

  1 件のコメント

s0ter48
s0ter48 2019 年 11 月 18 日
Hey,
sorry for the late response.
I dont think it will work with an enabled subsystem.
I buid an example to show u.
At the end there are no flanks anymore so I want a 0 at this point but how can i realise this?

サインイン to comment.

サインイン してこの質問に回答します。


Translated by