Lookout

cancel
Showing results for 
Search instead for 
Did you mean: 

Expression or Calculation tag value are reset to last application saved value when PC reboot

I'm doing daily logging data for daily report and for the daily flow calculation, I'm doing those step:

 

1- When Timer1 = 11h55 -> Daily_Volume = (Actual_Volume - Yesterday_Volume)

2- When Timer2 = 11h56 -> Yesterday_Volume = (Actual_Volume )

3- When Timer3 = 11h58 -> Log to database Daily Volume


The problem is that when you restart the application or the PC, the calculation tag "Yesterday volume" reset to the last saved value.  

 

Exemple 2012-01-01 last saved application changes,

 

- 2012-01-01 my Actual_Volume = 1000 USGal moved to my Yesterday_Volume.

- 2012-01-02 my Actual_Volume (1100 USGal)  - Yesterday_Volume (1000 USGal) = Daily_Volume (1000 USGal) move the Actual_Volume to Yesterday_Volume.

- 2012-01-03 my Actual_Volume (1200 USGal)  - Yesterday_Volume (1100 USGal) = Daily_Volume (100 USGal)

...

We've got a power shutdown or any PC reboot.  On the 2013-01-01

- 2013-01-01 my Actual_Volume (19000 USGal)  - Yesterday_Volume (1000 USGal) = Daily_Volume (18000 USGal) move the Actual_Volume to Yesterday_Volume.

- 2013-01-02 my Actual_Volume (19100 USGal)  - Yesterday_Volume (19000 USGal) = Daily_Volume (100 USGal) move the Actual_Volume to Yesterday_Volume.

 

Those values reset to the last application saved value cause bad data in my daily, monthly, yearly reports.  How can we retain calculation tag value to avoid those reset problem?

0 Kudos
Message 1 of 3
(5,892 Views)

In Edit mode, File->Modify Process, there is an option "Save state file every xxx minutes". Is this one checked or not?

 

The value of objects should be saved in the state file when you close the process, or periodically saved according to this setting. The saved value will be loaded next time you open the process.

Ryan Shi
National Instruments
0 Kudos
Message 2 of 3
(5,866 Views)

We've set it to 60 minutes and this seems to solve my issu.

 

Thank you!

0 Kudos
Message 3 of 3
(5,755 Views)