2 fn_or example, 3 fn_compare example – Echelon i.LON SmartServer 2.0 User Manual

Page 129

Advertising
background image

i.LON SmartServer 2.0 Programmer’s Reference

8-11

20 30 40 50

35

EMPTY 0.0

0

70 80 40 50

35

EMPTY 100.0

1

8.3.2.2.2 FN_OR

Example

In this example, there are four input data points and one compare data point, all of the type
SNVT_count. There is one output data point, of the type SNVT_switch.

<UCPToutputFunction>: FN_OR
<UCPTcompFunction>: FN_LT

Because the output function is FN_OR, and the comparison function is FN_LT, one of the values of
the data inputs must be less than the value of the compare data point, or the <UCPTtrueThreshold>
value if it is defined, for the output data point to be set to True. If the <UCPTtrueThreshold> property
is defined, then value of the compare data point is not used in the comparison.

The following table lists several case scenarios that show when these two functions might evaluate to
True (100.0 1).

Input 1

Input 2

Input 3

Input 4

Value of Compare Data

Point

UCPTtrueThreshold Output

9

11 12 13

Does

not

matter

since

<UCPTtrueThreshold> is

defined.

10 100.0

1

20

30 40 50

15

EMPTY 0.0

0

20

30 40 50

25

EMPTY 100.0

1

20

30 40 50

35

EMPTY 100.0

1

8.3.2.2.3 FN_COMPARE

Example

In this example, there are four input data points and one compare data point, all of the type
SNVT_count. There is one output data point, of the type SNVT_switch.

<UCPToutputFunction>: FN_COMPARE
<UCPTcompFunction>: FN_EQ
<UCPTmajorityValue>: 100

Because the <UCPTmajorityValue> is set to 100, all comparisons made between the input and
compare data points must return True for the output data point to be set to True. The comparison
function selected is FN_EQ, so this means the values of the input data points must match the value of
the compare data point, or the <UCPTtrueThreshold> property if it is defined, for this to happen. If the
<UCPTtrueThreshold> is defined then the value of the compare data point is not used in the
comparison.

The following table lists several case scenarios that show when these two functions might evaluate to
True.

Input 1

Input 2

Input 3

Input 4

Value of Compare Data Point

UCPTtrueThreshold

Output

50

30

50

50

Does not matter since

<UCPTtrueThreshold> is defined.

40 0.0

0

40

40

40

40

Does not matter since

<UCPTtrueThreshold> is defined.

40 100.0

1

50 50 50 50

50

EMPTY

100.0

1

50 50 50 49

50

EMPTY

0.0

0

Advertising