How to add Stateflow event listeners?

조회 수: 1 (최근 30일)
Ajay krishna Vasanthakumar
Ajay krishna Vasanthakumar 2020년 12월 9일
댓글: Ajay krishna Vasanthakumar 2021년 7월 12일
Hello all,
For Simulink blocks we add add_exec_event_listener to obtain the run time object of block
In similar way do matlab have provision to add the listener for states and transitions?
Can someone help me out?
Thanks,
V. Ajay Krishna

채택된 답변

Ntiana Sakioti
Ntiana Sakioti 2021년 7월 1일
Hi Ajay,
If you are interested in identifying when a state has been entered and exited you can use implicit events enter("stateName") and exit("stateName") as listed in this documentation page. You can also identify when a transition is being taken by using "send(TransitionTaken)" as a transition action, where "TransitionTaken" is an event.
Hope this helps.
  댓글 수: 1
Ajay krishna Vasanthakumar
Ajay krishna Vasanthakumar 2021년 7월 12일
Thanks Ntiana :). This will be helpful for sure

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Complex Logic에 대해 자세히 알아보기

제품


릴리스

R2016b

Community Treasure Hunt

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

Start Hunting!

Translated by