Hakan Posted July 13, 2005 Report Share Posted July 13, 2005 Hello! How do you define a static variable in a subvi? I'm implementing a small .vi that is supposed to check wheter the input value has changed or not. Best regards, H Quote Link to comment
m3nth Posted July 13, 2005 Report Share Posted July 13, 2005 Control values are static if they are not wired to the connector pane, so you can write to them using a local variable and compare the value later. A better implementation is to use LV2 style functional globals by creating a loop with an unitialized shift register and a case statement inside the loop to select the action that will either set the shift register or compare the last value. Since the shift register is uninitialized it will not change values between subvi calls. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.