From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Adjustable Calibration

To start, I am brand new to LabView so I appologies for my unsophisticated question.  I am using LabView 8.6 and currently collecting 4 analogue signals from a NI USB6009.  I have created a calibration curve for these signals to convert the voltage reading into degrees of rotation (the signals are from 3 Novotechnik P2501 potentiometers) and torque in Nm (the signal is from 1 Transducer Techniques SWS250 torque cell).  However, I need to be able to modify my calibration curve to account for the minor changes in readings due to changes in temperature in the room and accidental bumping...meaning I need to be able to press a buttom that will grab a data point.  I then need to be able to subtract the value of that data point from all other measurements made.

 

For example, this morning with the platform level, one of the potentiometers read .37 degrees of rotation.  That means that every data point I collect for the rest of the day is off by .37 degrees.  So I need to subtract .37 from every data point I collect throughout the day.

 

Any advice would be extremely helpful, but please keep in mind that I am still learning my way around this software.  Thanks!

Message Edited by Clemson11 on 06-09-2009 02:06 PM
0 Kudos
Message 1 of 9
(4,029 Views)

Clemson11,

 

Hello! You could setup two Data Acquisition Tasks such that the first one ran as a "calibration" to grab your offset value and the second one ran to acquire data. In doing this you could subtract the offset value received in the first Data Acquisition from the actual values in the second Data Acquisition.

 

How are you doing your Data Acquisition and Custom Scaling? By this I mean are you using DAQmx Vi's or the DAQ Assistant? Have you created a Custom Scale in Measurement and Automation Explorer, in LabVIEW with the DAQmx Vi's, in the DAQ Assistant, or by using math functions in your post processing? Knowing these specifics would help me give you a more specific answer.

 

Thanks!

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Ben Sisney
FlexRIO V&V Engineer
National Instruments
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
0 Kudos
Message 2 of 9
(3,997 Views)

I am using the DAQ assitant for both data aquisition and custom scaling.

 

Thanks

0 Kudos
Message 3 of 9
(3,994 Views)

Clemson11,

 

With the DAQ Assistant, there isn't a way to pragmatically edit your custom scale. What you set in the DAQ Assistant Wizard is what the custom scale will be during your data acquisition. This leaves two options:

 

1.) Use DAQmx to do your data acquisition and edit your custom scale pragmatically with some sort of constant before your data is acquired.

2.) Use the Math Functions of LabVIEW to manipulate your data in post processes with some sort of offset.

 

Here is some good information on this Topic.

 

How do I make a custom scale in the Measurement and Automation Explorer (MAX)?

DAQmx Acquire with Custom Scale

Programmatically Create a Custom Scale in DAQmx

Changing the Values of a Custom Scale Programmatically

Getting Started with NI-DAQmx: Main Page

Learn 10 Functions in NI-DAQmx and Handle 80 Percent of Your Data Acquisition Applications

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Ben Sisney
FlexRIO V&V Engineer
National Instruments
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
0 Kudos
Message 4 of 9
(3,977 Views)

I have had to do this, too.  What I did was add a button (labeled "Zero").  When I pressed the button, the VI would read the current position and add that to the zeroth order calibration coefficient -- I didn't use the scaling.  It may be easier to keep track of an offset and add that after the scaling.

 

-Matt Bradley

************ kudos always appreciated, but only when deserved **************************




0 Kudos
Message 5 of 9
(3,970 Views)

Ben S Thank you for the links, I will look over them and see what I can learn!  Matt Bradley, that is exactly what I want to do, my question now is how do you read the current position and add that to the zeroth order calibration coefficient.  I understand that I need a button control using a case structure, I just dont know how to program the "memorize current position" so I can subtract it.

 

Thanks for the help.

0 Kudos
Message 6 of 9
(3,966 Views)

Clemson11,

 

Check out this example I found on the community, I think it may do what you're looking for, or at least point us in the correct direction.

 

Calibrate to Zero for DAQ Assistant (tare)

 


MattBradley,

What do you mean by "zeroth order calibration coefficient". Were you using DAQmx or Traditional DAQ? I've looked through all the DAQmx Property Nodes and haven't found anything by that name.

Message Edited by Ben S on 06-10-2009 04:54 PM
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Ben Sisney
FlexRIO V&V Engineer
National Instruments
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
0 Kudos
Message 7 of 9
(3,958 Views)

Ben S, That link looks exactly like what I want to do.  This is virtually like a tare function on a digital scale.  I believe what matt Bradley ment by the zeroth order was for example y=mx+b, the b term is essentially bx^0, in this case the x becomes 1 because any number raised to the zero power (zeroth order) is 1 so the result is just 1b.

 

I will try to gather as much as I can from the link you sent and will post any questions I have.  thanks!

0 Kudos
Message 8 of 9
(3,950 Views)

Here is a very simple way to adjust an offset 

It needs to be placed in a Loop, but I asume that exists anyway.

 

simple zero_BD.png

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


0 Kudos
Message 9 of 9
(3,925 Views)