The example below shows how to configure filling of retention tank based on measurement of minimum and maximum water level.
Configuring Equation Smart Rule
Equation Smart Rule has internal variable called LastState. This variable returns TRUE or FALSE based on last result of evaluation of this Smart Rule.
(LastState AND !St1) OR (!LastState AND !St)
If result is TRUE: Valve ... Turn On
If result is FALSE: Valve ... Turn Off
Minimum duration ... 0:05:00 minutes