LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I initialize a shift register when I run the vi for the first time?

Here is a shot of the sub vi I am running. The purpose of this vi is to zero and average my pressure transducer reading. My problem is when I start the vi the first time the zero function will work properly, the second time the zero function (when used) returns the last value in the shift register, the third time it will work again and so on. I am not sure if it is a shift register problem or the first call function. I am new with labview so maybe I am missing something!!

 

Thanks,

joew

0 Kudos
Message 11 of 14
(721 Views)

Hi joew,

just connect a constant to the shift register solves your problem. Right click on the left part of the shift register and select "create" -> "create constant".

 

Mike

0 Kudos
Message 12 of 14
(718 Views)
I tried to initializing it this way but when I do this I can not zero my reading.
0 Kudos
Message 13 of 14
(710 Views)

It looks to me like the problem is your "Zeroing". In the right hand Case, which your Zero-button connects to, just place a constant "0" in the False and send it to the shift register. That would set the Shift register to 0 on the next loop.

 

/Y

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

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 14 of 14
(704 Views)