Cicode Programming Reference > Using Cicode Expressions > Triggering Events Using Expressions

Triggering Events Using Expressions

Logical expressions - those that return either TRUE (1) or FALSE (0) -can be used as triggers.

For example, you might need to log the expression in the above example only when an associated pump is running.

Trend Tag Name

B1_TIC

Expression

B1_TIC_101_PV + B1_TIC_102_PV

File Name

[log]:B1_TIC

Trigger

B1_PUMP_101_CMD

In this example, the trigger is the expression B1_PUMP_101_CMD (a digital variable tag). If the pump is ON, the result of the trigger is TRUE, and the value of the expression (B1_TIC_101_PV + B1_TIC_102_PV) is logged. If the pump is OFF, the result is FALSE, and logging ceases.

See Also

Using Cicode Expressions