Calculating the rate of change of a variable using RTES
|
Variables |
Analog Input : PRESSURE Registers : R0017 P0 R0028 RATE R0029 PSX R0030 PS |
|
Rules |
RULE RATE=100*(P0+P1+P2-P3-P4-P5)/P2 |
|
Notes |
This example uses the SHIFT function. Whenever the expression associated with SHIFT changes from false to true, the registers referenced by the next two registers are shifted one position down. RATE contains the rate of change of PRESSURE - in % - over the last 6 readings. A positive value means that is increasing, a negative value means that it is decreasing. Registers P0 through P5 must be consecutive. |