01-25-2013 03:50 PM
I've never scaled input from a DAQ, so I'm not sure if I'm approaching this the right way. I'm trying to scale the output of a wind velocity sensor using the data provided by the manufacturer, which is as follows:
Flow Velocity (m/s) 0 2 4 6 8 10
Output Voltage (VDC) 1.00±0.24 1.94±0.24 3.23±0.24 4.25±0.24 4.73±0.24 5.00±0.24
So I think what I need to do is generate polynomial coefficients and use those to create a scale for use with DAQmx.
My problem relates to the x vs y values. I assume that the scale works by taking a reading, putting it on the x axis, and finding the y intercept of the polynomial equeation. To generate those coefficients I am using the Curve Fitting VI. If I put Flow Velocity on the X axis and Output Voltage on the Y, the VI generates a curve that looks just like the curve from the data sheet of the sensor. But if I need to use the X axis as the input I have to reverse this. When I use Voltage as the X axis, the Curve Fitting VI doesn't seem to put out a curve that looks right. I've messed around with the power or the polynomial or other curve fits but it doesn't seem correct. I've attached a VI to show what I mean.
Not sure if I'm even going about this the right way.
01-25-2013 06:01 PM - edited 01-25-2013 06:02 PM
I don't use express VIs, and you failed to attach all subVIs, so here's what you could do instead. (LV 8.2)
01-25-2013 07:59 PM
Thanks you very much for the response and for building that VI. Very helpful. I'm going to need to study this for a while to understand it. The program can't seem to find a subvi "Ramp Pattern by Samples". Any chance you could post it?
01-25-2013 08:00 PM
By the way, why don't you use express VI's?
01-25-2013 08:33 PM
@LiveEveryDay wrote:
By the way, why don't you use express VI's?
...because I don't use dynamic data. 😄
(... and vice versa 🐵
01-26-2013 02:23 AM
The program can't seem to find a subvi "Ramp Pattern by Samples". Any chance you could post it?
01-26-2013 03:37 AM - edited 01-26-2013 03:37 AM