11-29-2007 02:06 PM
11-29-2007 02:12 PM
Tried to look at your code, but came up mostly blank since I don't have ni-Scope or ni-Switch installed, nor have I ever used either one.
Stepping up from 8-bit to 14-bit would *probably* reduce the high-freq noise that I attributed to quantization error. It appears you now have 8 bits = 256 quantized levels covering a 10 V range. 10 V / 256 gives a quantization resolution of about 40 mV. An extra 6 bits on the A/D converter changes the resolution by a factor of 64, putting it under 1 mV.
However, the real-world is probably putting some noise on that signal and it's difficult to predict how much. At some # of bits, the noise will be the dominant concern rather than the A/D resolution. Still, the extra A/D resolution will *definitely* be helpful to any software filtering or other post-processing you do.
You've expressed concern about software processing time -- can you put it in detail? What is a desired amount of software post-processing time? What is the most you'd be willing to live with, grudgingly? How much data must be processed in this time? Given what I've gathered thus far, I'd suspect that it's possible to do this stuff in single digits of seconds, if that. May take some work though...
-Kevin P.
11-29-2007 03:34 PM
11-29-2007 04:07 PM
11-29-2007 05:17 PM
11-29-2007 05:36 PM
I'll second Lynn's suggestions re: linear regression on transition regions. The only possible tweak is if the physics of the situation dictates fitting to something other than a straight line. (For example, an RC charge and discharge ought to be fit to an exponential).
I can't back this up with statistical theory, but you'll probably be wanting somewhere in the range of 25 to 100 data points to use for the curve fit. Too few points makes you susceptible to individual outliers while excessive points consume CPU with very little benefit in the calculated result.
0.03 seconds of acquisition? Is this 1 or 2 full revs at medium to high speed? Also, I'm surprised that software filtering seems to double your computation time. That sounds like the penalty one might pay when allocating new memory for a data copy of a very large (tens of MB) data array. Does the raw data go straight into the filter function or do you have a wire node that might cause LabVIEW to make a copy?
-Kevin P.
11-29-2007 05:41 PM
11-29-2007 06:10 PM
11-30-2007 08:24 AM
11-30-2007 04:55 PM