Main Content

View Sample Time Information

金宝app®模型可以显示代表特定样本时间的颜色编码和注释。每个样本时间类型都有与之关联的一种或多种颜色。您可以以彩色显示块和信号线,以黑色或两者的方式显示注释。选择以下选项之一:

  1. 在Simulink模型窗口中启用颜色金宝appDebug选项卡,选择信息叠加>颜色

  2. 启用注释Debug选项卡,选择信息叠加>文本

选择两者颜色and文本displays both the colors and the annotations. Regardless of your choice, Simulink performs an更新模型自动地。

关闭颜色和注释:

  1. Debug选项卡,选择信息叠加>颜色禁用颜色。

  2. Debug选项卡,选择信息叠加>文本to disable annotations.

金宝appSimulink执行另一个更新模型自动地。

Your Sample Time Display choices directly control the information that the Timing Legend displays.

笔记

这discrete sample times in the table样本时间信息的名称represent a special case. Five colors indicate the speed through the fifth fastest discrete rate. A sixth color, orange, represents all rates that are slower than the fifth discrete rate. You can distinguish between these slower rates by looking at the annotations on their respective signal lines.

Inspect Sample Time Using Timing Legend

您可以查看单个模型或多个模型的定时图例。此外,当您选择选项时,您可以防止传说自动打开采样时间菜单。

为了帮助您解释框图,定时图例包含模型中每个示例时间的样本时间颜色,注释和值。查看传奇:

  1. 在Simuli金宝appnk模型窗口中造型选项卡,单击更新模型

  2. Debug选项卡,选择信息叠加>传奇or pressctrl + j

另外,当您选择颜色or文本, Simulink updates the model diagram and opens the legend by default. The legend contents reflect your choices. If you turn colors on, the legend displays the color and the value of the sample time. Similarly, if you turn annotations on, the annotations appear in the legend.

图例显示模型中存在的样本时间,按样本时间的类型进行分类。

传说提供了两种突出显示的选项:

  • 突出显示样本时间起源的块和信号。

  • 强调ing all the blocks and signals that contain the selected sample time.

To enable highlighting of the origin of the sample times, click the起源来自强调菜单。您还可以单击样品时间的类型,以突出显示特定类型的样本时间的所有来源。

要启用所有包含选定样品时间的块的突出显示,请单击全部来自强调菜单。您还可以单击样本时间的类型,以突出显示包含选择样品类型类型的所有块和信号。

没有任何来自强调菜单清除当前的突出显示。

这个按钮当存在离散样品时间时,将离散值显示为1/周期。单击时,离散期表示为1/erige;对于非零偏移,它显示为偏移/周期​​。图像在模型中显示1/周期值和相应的突出显示块。

笔记

定时图例显示模型中的所有示例时间,包括与任何块无关的样本时间。例如,如果固定步长为0.1,并且所有块的样本时间为0.2,则在图例中两个速率(0.1和0.2)出现。

有关传说的后续查看,请更新图表以访问最新的已知信息。

If you do not want to view the legend upon selecting示例时间显示

  1. In the Simulink Editor, on the造型选项卡,选择Environment>金宝appSimulink首选项

  2. In the一般的窗格,清晰Open the timing legend when the sample time display is changed然后单击申请

在整个模型中检查样品时间

这模型数据编辑器(on the造型选项卡,单击模型数据编辑器) shows information about model data (signals, parameters, and states) in a sortable, searchable table. The采样时间列显示了模型中每个信号指定的示例时间。更新框图后,列还显示了每个信号使用的特定示例(例如,对于指定继承的示例时间的信号,-1)。您也可以使用此列指定样本时间。

有关模型数据编辑器的更多信息,请参阅使用模型数据编辑器配置数据属性

也可以看看

||