LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Help with zeroing strain signal

Hi,

 

I'm still learning how to use LabView and for a project, I'm using a DAQ to collect strain data. A thought that came to mind is if there is any strain build up between testing conditions that could create an offset in the data. Right now, I do go into the DAQ and make sure to calibrate the strain gauges but if there is an issue where at the start of testing, the signal is not ~0 I would like a way to click a "zero" button to eliminate any strain offset.

 

Would anyone be able to help offer any advice on how I can do so? I attached my current vi. set up for reference.

 

Thank you.

0 Kudos
Message 1 of 4
(1,459 Views)

I can't comment on code as I don't have LV 2021 installed.

 

What I've done:

 

1. On button click, start capturing strain gauge data.   (In some instances, I'll first popup a dialog for the user to confirm that the system is really in its neutral no-load state.)

 

2. Evaluate an appropriate-sized block of data for "stability".   The definition of both appropriate size and stability may change from situation to situation, but I often rely on a simple linear fit and make sure slope is near enough 0 and the R^2 correlation coefficient is near enough 1.  Again, exactly what constitutes "near enough" varies by situation.

 

3. Once the data establishes that the strain gauge shows acceptable stability, I'll take some kind of average (regular mean in well-behaved cases, median in the presence of "spiky" outliers) and hold onto it as my "tare value".

 

4. For all subsequent measurements, subtract the tare value from the reading.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Kudos
Message 2 of 4
(1,433 Views)

@Kevin_Price wrote:

I can't comment on code as I don't have LV 2021 installed.


Here it is, saved for LabVIEW 2019.  I'll let Kevin comment, as he has more experience with this than I.

Bob Schor

0 Kudos
Message 3 of 4
(1,414 Views)

I can look at the code now (thanks, Bob!), but don't really have much to add.  My general thoughts are the same,  The specific steps needed to "get there from here" are more than I can walk through in detail.

 

A few keywords to get started: event structures, shift registers, parallel loops, queues or channel wires, native DAQmx rather than DAQ Assistant.

 

 

-Kevin P

 

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Kudos
Message 4 of 4
(1,386 Views)