12-17-2012 05:56 PM
Hello,
I am measuring strain (using four 350 ohm gages) using a NI 9237 with a cDAQ in a Full Bridge Type 3 connection. My test involves measuring the strain over long periods of time (~ 10 days). The NI 9237 measures the strain at a rate of 2000 Hz (this is the slowest rate). The wheatstone bridge is being powerd with the NI 9237 by 2.5 V. When I obtain my data continuously, I see the strain increasing with time (which it should not be doing for my test) and I suspect that it is due to self heating of the strain gages. So, to get over this problem I am thinking of using the "Wait(ms)" function and ask the program to get data once every 5 min. The 5 min should be more than sufficient to dissipate any heating of the gage.
My question is: If I use the the "wait (ms)" function, is my sensor (strain gage) being continuously powered on during the wait time of 5 min ? I think the "wait" functions are used inside a loop to allow a VI to sleep for the prescribed time (correct me if I am wrong). So, does this mean that the sensor is not powered during this time ?
Thanks,
Sid
Solved! Go to Solution.
12-17-2012 06:38 PM
i wouldnt use "wait" function for your software timing...you can use elapsed time or any of the other timing functions
12-17-2012 08:49 PM
What's wrong with using the "wait" function ?
12-17-2012 08:55 PM - edited 12-17-2012 08:57 PM
If you have a long wait function within a loop, nothing can happen until that time is up. Suppose you decide to hit the stop button. You'll be forced to wait up to 5 minutes for the wait to finish (possibly almost up to 10 minutes depending on the way your code is setup) for the VI to detect the stop and end the loop. Someone will thing the program has hung up. If you have a quicker loop, but a case structure that only executes when the Elapsed time has occurred, then you can react quickly to other events such as the user hitting the stop button.
Be careful. If you have self heating of the strain gages, measuring the gage only periodically instead of continuously is probably not going to help you solve your problem. As long as the excitation voltage is applied in the strain gage bridge, current is flowing and the gages heating whether you are bothering to read the strain in the bridge or not.
12-17-2012 09:19 PM
I think I get your point. But can't I circumvent the problem of waiting for 5 min by not using the stop button and directly aborting the code ? Is it bad to hit the abort button. The worst case would be I will not be getting the last 5 min of data. Am I missing something. I am a new Lab view and I appreciate your help.
12-17-2012 09:21 PM - edited 12-17-2012 09:35 PM
@nssid wrote:
I think I get your point. But can't I circumvent the problem of waiting for 5 min by not using the stop button and directly aborting the code ? Is it bad to hit the abort button. The worst case would be I will not be getting the last 5 min of data. Am I missing something. I am a new Lab view and I appreciate your help.
you do not want to hit abort in software, this can cause undesirable results to equipment, among not properly running through shutdown procedures...
Certified LabVIEW Developer (CLD) Certification and Exam Overview
© 2012 National Instruments Corp. All rights reserved
Page 9 of 13
b. Timing functions
1. Use the Wait function to control the loop execution rate and allow the processor to respond to external events and system tasks
2. Use the Wait Until Next ms Multiple function to control the loop execution rate and to synchronize multiple loops
3. Avoid using any of the Wait functions to time a software operation
4. Use the Tick Count function and the Get Date/Time in Seconds function to time software operations
5. Account for time wrap when using the Tick Count function
6. Warn user of errors that result due to changes to the system clock if using the Get Date/Time in Seconds function
12-18-2012 12:36 PM
Thanks apok and ravensfan !!