Main Content

在事件广播或指定时间执行图表

描述

例子

在(N.E.的)回报true如果是事件E.已经发生了N.由于相关国家变得活跃的时间。否则,操作员返回错误的

例子

在(N.tick的)回报true如果图表已完全唤醒N.由于相关国家变得活跃的时间。否则,操作员返回错误的

隐含事件tick状态流不支持金宝app®在Simulink中的金宝app图表®模型有输入事件。

例子

在(N.的)回报true如果完全是N.由于相关国家变得活跃,因此已经过去了秒。否则,操作员返回错误的

在Matlab的独立图表中®, 指定N.值大于或等于0.001。这operator creates a MATLABtimer生成隐式事件以唤醒图表的对象。马铃薯草timer物体限制为1毫秒精度。有关更多信息,请参阅独立图表中的事件

  • timer当图表完成执行时创建对象entry相关状态及其代价物的动作。如果您指定N.作为在图表执行期间的值更改的表达式,图表不会调整时间延迟timerobject.

  • timer当关联状态变为活动状态时,对象在图表步骤的末尾开始运行。该步骤可以包括图表中的其他并行状态的执行。

  • 如果图表正在从中接收隐式事件时处理另一个操作timer对象,图表队列事件。完成当前步骤时,图表将处理该事件。

  • 如果与时间逻辑运算符相关联的状态在图表处理隐式事件之前变为无效,则事件不会唤醒图表。

笔记

使用由于绝对时间逻辑运算符仅在Matlab中的独立图表中支持。金宝app对于Simulink模型中的金宝app图表,使用operator instead. For more information, see不要在Simulink模型中用于图表中的绝对时间逻辑金宝app

例子

展开全部

当图表处理事件的第三个广播时显示状态消息E.州活跃后。

在(3,e):disp(“开”);

状态溢图在状态下使用AT运算符。

Transition out of the associated state when the chart processes the fifth broadcast of the eventE.州活跃后。

在(5,e)

州流程chart that uses the at operator in a transition.

如果状态为事件的恰好五广播为中心,则过渡出相关状态E.

在Simulink模型中的图表金宝app中,输入:

[在(5,e)]]

州流程chart that uses the at operator in a transition.

Conditional notation for temporal logic operators is not supported in standalone charts in MATLAB.

Transition out of the associated state when the chart wakes up for the seventh time since the state became active, but only if the variabletempis greater than 98.6.

在(7,刻度)[temp> 98.6]

州流程chart that uses the at operator in a transition.

设定temp变量到高的如果该状态恰好有效12.3秒。

在Matlab的独立图表中,输入:

在(12.3,秒):temp = high;

状态溢图在状态下使用AT运算符。

使用每一个as an absolute-time temporal logic operator is not supported in charts in Simulink models.

提示

  • 您可以使用引号括在关键字'打钩'and'秒'。例如,在(5,'tick')相当于在(5,勾选)

  • StateFlow图表重置了所使用的计数器操作员每次关联状态都重新激活。

  • Matlab中的独立图表在壁钟时间方面定义了绝对时间的时间逻辑,限制为1毫秒精度。

版本历史记录

Introduced in R2014b