02-20-2012 03:03 AM
Hello,
I am trying to read 19 Pressure transmitter values.
2 PT are 0-350bar
other 17 are 0-200bar.
as per the equation y-mx+c
I want to generalize and set the values to each PT.
using some code, farmula node......also if I consider each PT it takes lot of space in the main VI.
Please see the attached and give some suggestions.
Solved! Go to Solution.
02-20-2012 10:32 AM
1. To use the formula node you need to assign names to the input and output variables.
2. You do not define c.
3. This can probably be done as easily with LV primitives rather than a formula node.
4. Create an array of the scaling factors.
Lynn
02-21-2012 01:44 AM
Thank you!
I have some questions:
1. the output array of the subVI is 1Dimensional and just give the value of index 0,1,2.But I have two types of pressure transducer 0-350(PT1 toPT3) and 0-200 bar(PT4 To PT19). How can I get the scaling values?
2. What about using the Linear fit? How can I use it? for two types of array based data?
Extension of the VI:
1. I want the value which is acheived from the PT1, PT2, PT 3 (all 0-350bar) should checked for upper limit=85bar and lower limit=20bar? A graph should be plot?
2. The mean and standard deviation of all PT values should be calculated and a histogram should be formed?
I have tried to develop the code. Please suggest.
02-21-2012 02:33 AM
Instead of using the MathScript node you can use the Polynomial Evaluation point by Point by giving the Gain and Bias value as an array for to the transducer output for the transducers depending on its range.
02-22-2012 02:04 AM
Hello,
I have some questions:
1. the output array of the subVI is 1Dimensional and just give the value of index 0,1,2.But I have two types of pressure transducer 0-350(PT1 toPT3) and 0-200 bar(PT4 To PT19). How can I get the scaling values?
2. What about using the Linear fit? How can I use it? for two types of array based data?
3. I tried with polynomial function, but I am not sure how to sue it?
Extension of the VI:
1. I want the value which is acheived from the PT1, PT2, PT 3 (all 0-350bar) should checked for upper limit=85bar and lower limit=20bar? A graph should be plot?
2. The mean and standard deviation of all PT values should be calculated and a histogram should be formed?
3. The mean and standard deviation is always giving infinite value?
I have tried to develop the code. Please suggest.
02-22-2012 02:51 AM
The main aim of the VI is:
1. Acquisition of 19 PT
2. Scaling the PT using some subVi or Linear-fit or Polynominal function
3. Checking the status of PT1, PT2, PT3 they should be 20 to 80 bar and give the status Overlimit or underlimit.
4. All the PT values should be shown in a graph, histogram, individually with the labels, PT1 to PT19 different bar.
5. Then all PT values mean should be calcuated and standard deviation and another histogram should be shown.
Please see the VI attached and sub VI's are attached.
02-22-2012 06:33 PM
I have looked at your latest VI. Without any data I cannot tell how well it is working.
For the labels read the detailed help files for the graphs. You may need to try some things to get it to look the way you want.
The Standard Deviation and Variance.vi also calculates the Mean so you do not need two VIs.
It looks like it has most of the features you want. Do you still have questions?
Lynn
02-23-2012 03:04 AM
1.The scaling is not proper as I used the logic it just gave the same constant values...but it should multiply with current PT value and give the output. I think there is some problem in the SubVI.It should give scaled values of 200bar and 350bar PTs.
2. All the graphs are not showing up.
3. Status graph of PT1, PT2, PT3 give strange sine waves.
4. None of the histogram can be seen.
Please suggest!
02-23-2012 03:05 AM
Another subVI for the program.
02-23-2012 11:01 AM
One issue is that your Scaling (SubVI) is pulling the data out of the rows of the scalling array constant rather than the columns as I suggested in my posting of 2-20. The image is difficult to see but the 1,0,2 constants are wired to the lower (column) inputs and you have those values wired to the upper (row) inputs.
Please post a version of PT3-2--2.vi with some data saved as default in the array called "data" -- the one coming out of the DAQ Read.
Lynn