Using triggered subsystem with either - need a reset but how?
조회 수: 6 (최근 30일)
이전 댓글 표시
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](https://www.mathworks.com/matlabcentral/answers/uploaded_files/245411/image.png)
I build an example so u can understand what I mean.
Thanks in advance. =)
댓글 수: 0
답변 (2개)
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!
참고 항목
카테고리
Help Center 및 File Exchange에서 Subsystems에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!