Showing results for 
Search instead for 
Did you mean: 

saving last value



I have got the LV 2009 VI attached underneath for reading a displacement (x) which comes from my RS232 PXI interface, converting it to an angle (gamma aero) and displaying it on the Frontpanel. This VI allows me to get Information about the actual angle while moving. I would like to modify in the VI Block to automatically save the last angle position where i stopped for more than 20sec. This would be then displayed on the front panel. I am totally new to Labview and would be happy to get any hint/help from anyone more experienced.


yours sincerely,

0 Kudos
Message 1 of 7

Usually you use a shift register or feedback node for storing values between itterations of a program.  Functional globals (also refered to as a form of action engines) are good architectures for generating a function for doing this as well.

Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 2 of 7

If your measurement works currently you should be able to put it all in a big while loop (it seems you already had a good delay), then read the value and the current time each loop.

Feed both to a shift register and you can read the previous value next loop. (Start time and measuerment)

If the Value is changed, send both to the shift register (small case), if Value is the same send a new start-time and check if time is >20 sec, if so update indicator.


Good Luck


G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Message 3 of 7

thanks a lot for the ideas!! however can you please provide me with a small example VI or even a hand sketch to understand your suggestion better, i am trying to build the shift register but not figuring out really how to start?how can i get the current time and feed it to the shift register together with the value? i would really appreciate it very much if you provide me with a hand sketch or so of your suggestion. I attached snapshots of my VI and sub VI. Note please that Alpha Aero is my Value.



Download All
0 Kudos
Message 4 of 7

This tutorial has info on shift registers and lots of other useful stuff.


To send the time and some other value to the shift register you can use a cluster. Or you can use a second shift register.

LabVIEW 2012

0 Kudos
Message 5 of 7



can anyone help me out on this VI, i am not sure if my approach was correct. I built the advice you gave me here, do you think this is ok?i am happy to receive all remarks for correcting my while loop.

0 Kudos
Message 6 of 7



i managed to test my VI attached. It worked out for the actual Alpha angle but still i cant read my Last Alpha angle. However, when i stopp my VI for 20s plus not move my Vanes for 20s, i got an update of this angle after running my VI again. I can figure out whats wrong with my VI? i want to get this update while running and not while the VI is aborted. Please help me out on this guys!

0 Kudos
Message 7 of 7