Viewer Channel Configuration (Preparation operators) Overview
OverviewViewer channel configuration operators, also called Preparation operators, belong to a class of operators that configure properties of signals that are displayed in signal viewers.
All operators that display signals or properties of signals use the Preparation operators to get specific display properties that belong to a channel configuration.
Prepare Viewer Signals link: Enables the setting of multiple display properties for signals in viewers.
Prepare Ranges and Offsets link: Prepares settings of range and offset for signals in viewers.
Prepare Time Range link: Enables the setting of the time line in viewers.
Prepare Signal Graphics link: Enables the setting of graphical properties (such as colors) for signals in viewers.
Prepare Markers link: Selects the event markers that should be displayed in a viewer, and defines their display properties.
DetailsTo display signal data in a viewer, many properties can be specified about how the data should be displayed. In Polybench, those properties have been separated from any viewer operators. To specify how signals or other channel data are presented in any viewer, one or more Preparation Operators need to be connected to between the signal source and the viewer operator.
The figure below shows a typical setup, that sets the range and offset of the signals in the viewer; the time range of the viewer; and the color of the signals.
Each channel at the input of the viewer component may have a separate set of properties, that, for example, determines what color the data has, or its range and offset.
Also some general properties, such as the Time Range of the viewer, can be set outside the viewer component.
The preparation operators work with real-time streaming data, but also with stored data. Streaming data is lead through these operators without change and without delay.
But also stored data is lead through these operators, which is a special feature of this kind of operator. It is allowed to place a Preparation Operator between a Storage and a Y-T Reviewer; the Y-T Reviewer is then still able to get data from the storage. Normally, there must be a direct connection between a reviewer and a stored data source, otherwise the reviewer cannot "see" the stored data. However, the Preparation Operators are kind of transparent to stored data, because they do not actually do anything with the signal data.
The figure below shows a false review setup (top) and a correct review setup (bottom). The first reviewer cannot read stored data, because a Channel Terminal blocks the reading. The second reviewer can read the stored data that is offered by the Storage operator, although a preparation operator is in between the storage and the reviewer.
Connection possibilitiesTo view data, one or more Preparation Operators are required in series with the viewer operator. More than one viewer can be connected to a Preparation Operator. If that is the case, all connected viewers will inherit the same channel properties.
If multiple preparation operators are put in series, then the settings are combined. If a later operator in the chain sets the same properties as a preparation operator earlier in the chain, the last operator's settings are used.
The figure below shows a few connection schemes that are allowed. To explain in words: Both Y-T Viewers and the Value Viewer share the same channel graphics properties (colors). Both Y-T Viewers share the same range and offset settings for all channels. Y-T Viewer 2 has an additional time range setting (Y-T Viewer 1 uses a default time range of 10 sec).
Disconnecting a connector: when are settings deletedIf the input connection of a preparation operator is deleted and the input is re-connected to a different data source, or to a different Channel Terminal node, then the settings in the preparation operator are lost, because they are bound to a specific set of channels.
If the connection is deleted and then the same source is reconnected, the settings are recovered.
Prepare Viewer Signals operator has them allDifferent kinds of channel display settings have been broken down in separate preparation operators, so that you can freely add or leave settings for one or more viewers. However, often you will need all available settings to be able to make a good signal viewer preset. In that case you should use the Prepare Viewer Signals operator (link). In the toolbox this operator is clearly marked with a plus symbol.
A typical setup is that the first preparation operator in a row is the general Prepare Viewer Signals operator, followed by a few specialized preparation operators to refine the settings. Especially if you want to control certain properties using variable parameters, you will need the specialized preparation operator, as is explained below.
Changing channel display settings from within the applicationThe general Prepare Viewer Signals operator does not offer any variable parameters (link). However, the single-function preparation operators do! Using variable parameters, graphical properties of the signals can be changed from within your project. Read more about available parameters and functions in the documentation for the specialized preparation operators that are listed above.
WARNING: duplicate channels! Use a Channel Terminal before the inputThis warning is sometimes displayed below a preparation operator.
Sometimes it is required to insert a Channel Terminal (link) in a line of operators, to ensure that all channels are uniquely recognized. If at some earlier point in the schematic flow, channels of one source are doubled (e.g. by a Channel Merger), then not all channels in the bus are unique.
If this is the case, the preparation operators display a warning, because they base their settings on unique channel characteristics. The Signal Monitor Probe (link) can show the identifiers of the channels, and also shows which channels are duplicated.
If the warning is displayed (below the symbol), then put a Channel Terminal before the preparation operators (but not in between!).
The figure below shows a typical setup where a single channel is duplicated by means of a Channel Merger (link). The result is that at the output of the Channel Merger the signal bus contains two channels that both have the same identifier. As a result, the preparation operator and the viewer show a warning about that.