beautypg.com

2 comparison functions – Echelon i.LON SmartServer 2.0 User Manual

Page 128

background image

i.LON SmartServer 2.0 Programmer’s Reference

8-10

8.3.2.2 Comparison Functions

The following table lists and describes the comparison functions you can use to fill in the
property. You must reference each function by the identifier listed in the table.

Identifier Description

FN_GT

Greater than. Returns True if the value of the input data point is greater than
that of the compare data point (or the value assigned to the
property, if it is defined).

FN_LT

Less than. Returns True if the value of the input data point is less than that
of the compare data point (or the value assigned to the
property, if it is defined).

FN_GE

Greater than or equal to. Returns True if the value of the input data point is
greater than or equal to that of the compare data point (or the value assigned
to the property, if it is defined).

FN_LE

Less than or equal to. Returns True if the value of the input data point is
less than or equal to that of the compare data point (or the value assigned to
the property, if it is defined).

FN_EQ

Equal. Returns True if the value of the input data point is equal to that of
the compare data point (or the value assigned to the
property, if it is defined).

FN_NE

Not equal. Returns True if the value of the input data point is not equal to
that of the compare data point (or the value assigned to the
property, if it is defined).

FN_NUL

No comparison function is used. This is true if is
set to FN_MAX, FN_MIN, FN_SUM, or FN_AVERAGE.

8.3.2.2.1 FN_AND

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.

: FN_AND
: FN_GT

Because the output function is FN_AND, the comparisons made with all the input data points must
return True for the output data point to be set to True. The comparison function is FN_GT, so the
value of each input data point must be greater than the value of the compare data point, or greater than
the value of the value (if defined) for this to happen. If the
property 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 functions might would 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

is defined.

10 0.0

0

20

30

40

50

Does not matter since

is defined.

10 100.0

1