AnsweredAssumed Answered

PI UFL- compare values to previous line before StoreInPI()

Question asked by ntremblay on Jan 12, 2016
Latest reply on Jan 19, 2016 by ntremblay

We are currently importing data from some Equipment using the PI UFL interface to parse CSV files.  However, upon the Equipment powering off the values exported for certain points (especially counters) start winding down to 0 before the data aquisition stops, thus we have a few counters, which should always be increasing (or staying at the same level) that start trending downwards, thus causing issues with certain calculations.

 

I know that I can compare the current value to a fix amout ( If TotalFuelUsed != 0 then StoreInPI(...) ), but is there a way to compare values to the line above it?

          EXAMPLE

               11/01/2016 11:58:14.000,[..],[..],[..],[..],109086.0000000000,,[..],[..],[..],[..]

               11/01/2016 11:58:14.500,[..],[..],[..],[..],108176.9500000000,[..],[..],[..],[..]

               11/01/2016 11:58:15.000,[..],[..],[..],[..],107267.9000000000,[..],[..],[..],[..]

               11/01/2016 11:58:15.500,[..],[..],[..],[..],106358.8500000000,[..],[..],[..],[..]

               ........skip to last line of data....

               11/01/2016 11:59:13.500,[..],[..],[..],[..],909.0500000000,[..],[..],[..],[..]

 

As you can see the data is on a noticable downward trend, and it makes for some confusing trends (used for troubleshooting calculations until the application is done and ready from production) as seen attached.

Attachments

Outcomes