Property Evaluation Types

There are five evaluation types you can apply to an element or Symbol property in the Graphics Editor:

Simple

Simple evaluations are the most basic type of property evaluation. Simple evaluations allow you to specify a one-to-one substitution or behavior for the expression result of the property, without setting any conditions.

Simple evaluations only require you select a property and enter an expression.

Animated

The Animated evaluation is used to change a property value by setting a value for each frame and then setting the interval times between frames and their associated values. In the Animated evaluation each value condition is considered a frame. One frame is used as the Off frame.

Linear

Linear allows you to broaden the range of the expression by mapping the expression result to a minimum and maximum range. The minimum and maximum values are set to the original expression range or you can manually enter a range. A range condition can be another literal value or a symbol from the symbol library. You can have multiple range conditions for each property expression. If a minimum or maximum range is blank, the value is taken from the expression range.

Discrete

Discrete evaluations allow you to map the expression result to one or more conditions. However, unlike the Linear evaluation, the conditions of the expression are evaluated and processed in order of priority from top-to-bottom in the Evaluation Editor view. The value of the first true condition is applied and all other conditions are not used.

You can use the And condition to compare individual bits of an analog data point expression. The And condition uses binary encoding to compare a hexadecimal value with the binary equivalent to see whether a condition is true. For example, the hexadecimal number 2A is equivalent to the binary value of 0010 1010, and the decimal value of 42. For any bit conditions that match the bit places of 2, 4, and 6 being OR or 1, the condition is true.

Multi

Multi evaluations allow you to create evaluations for digital data points. Every possible combination of digital data point states can have results which you can set or limit in your evaluation. The Tri-State check box allows you to manage the number of required conditions for your evaluation.

 

Animated Evaluations and Examples

The Animated evaluation is used to change a property value by setting a value for each frame and then setting the interval times between frames and their associated values. In the Animated evaluation each value condition is considered a frame. One frame is used as the Off frame.

Example:

You have a rectangle drawn on the canvas and would like to change the Fill property color. Each frame is set to the color you would like the Fill to be for that frame.

Discrete Evaluations and Examples

Discrete evaluations allow you to map the expression result to one or more conditions. However, unlike the Linear evaluation, the conditions of the expression are evaluated and processed in order of priority from top-to-bottom in the Evaluation Editor view. The value of the first true condition is applied and all other conditions are not used.

You can use the And condition to compare individual bits of an analog data point expression. The And condition uses binary encoding to compare a hexadecimal value with the binary equivalent to see whether a condition is true. For example, the hexadecimal number 2A is equivalent to the binary value of 0010 1010, and the decimal value of 42. For any bit conditions that match the bit places of 2, 4, and 6 being OR or 1, the condition is true.

Examples:

Example I

The Fill color of a rectangle should be depicted as follows:

  • Blue if the temperature is below -20
  • Red if the temperature of the water is 40 or above 40.
  • Orange for any other temperature. The design value of the rectangle is set to “Orange”.

Result

If none of the conditions is true, the design value, Orange, is applied. Optionally, a third color condition can be specified if the design color should be different from the default animated color. This could be relevant for the preview.

Example 2

You want to change the background color of an analog object depending on the value of data point 2 (dp2).

  • The first Condition is set to &1, and the Value is set to “Red”.
  • The second Condition is set to & 2A and the Value is set to “Green”.

Result

According to these conditions, the background color of the data point changes as follows:

  • “Red”, if the first bit is set to 1, and when the actual value of dp2 is 1, 3, or any other odd number, the condition is true.
  • “Green”, if the bits 2, 4, and 6 are set to 1. Therefore, when the actual value of dp2 is 42, 46, 254, or any value whose binary codes have the 2nd, 4th, and 6th bit set to 1, the condition is true.
  • If neither condition is =True, the background color is by default the design value.

Linear Evaluations and Examples

Linear allows you to broaden the range of the expression by mapping the expression result to a minimum and maximum range. The minimum and maximum values are set to the original expression range or you can manually enter a range. A range condition can be another literal value or a symbol from the symbol library. You can have multiple range conditions for each property expression. If a minimum or maximum range is blank, the value is taken from the expression range.

Examples:

Examples of how the Linear Evaluation can be used:

Example 1

Scenario: The Fill color of a rectangle is used to reflect the current water temperature. You can enable the Auto Range check box, and set the minimum and maximum temperature in Expression field.

  • The Fill color is set to dark blue to represent cold water (-50) and to light blue to represent a normal water (100) temperature.
  • The Auto Range check box is enabled for this scenario.
  • The Fill color changes according to the set temperature range.

Example 2

Scenario: Same as in Example 1, but the Auto Range is disabled, and a rate is set to 10…30.

  • The rectangle Fill color is dark blue for any expression values below 10, and
  • Light blue for any values above 30.

Example 3

Scenario: Same as in Example 1, but Auto Range is disabled.

  • The minimum range is set to 20; the maximum range is left empty.
  • If either the Min or Max condition value is empty, the corresponding minimum or maximum range is taken from the Expression range.
  • If the expression does not have a range, the values -1.79E+308 (Min) or +1.79E+308 (Max) are used.

 

Multi Evaluations and Examples

Multi evaluations allow you to create evaluations for digital data points. Every possible combination of digital data point states can have results which you can set or limit in your evaluation. The Tri-State check box allows you to manage the number of required conditions for your evaluation.

Example:

In the example below, the Text property is used to display the evaluated value of two data points.

Simple Evaluations and Examples

Simple evaluations are the most basic type of property evaluation. Simple evaluations allow you to specify a one-to-one substitution or behavior for the expression result of the property, without setting any conditions.

Simple evaluations only require you select a property and enter an expression.