12-07-2022 09:36 AM
I am looking for guidance on my VI. This is theoretical currently and am building this slowly from easy to more complex as I am new to LabVIEW.
Suppose you have 4 wheel speed sensors and you want to find the average MPH you are traveling, that I have done. Say one of these sensors is not reading accurately, you would still want to know how fast you are going by excluding the one or more sensors that are not reading accurately. Currently I have a tolerance of +/- 2MPH.
I have many true/false statements checking sensors against each other. Depending on the true false array, this would tell me if they are all working or if one or more are at fault and which ones.
A list of all trues would indicate that all sensors are working.
However, I list with
all trues except
1/3 = False
2/3 = False
4/3 = False
would should sensor three is the faulty sensor and I can exclude that sensor from my average. my next step would to display a message of the faulty 3rd sensor.
I am completely lost on my next steps, nor am I sure if I have the correct VI's in here to do so. I know I need 5 cases at minimum.
1. Average all 4 wheel speeds (Default)
2. Average 1/2/3 and exclude 4
3. Average 2/3/4 and exclude 1
4. Average 3/4/1 and exclude 2
5. Average 4/1/2 and exclude 3
FYI, I am aware I have the rolling average of all 4 on display. once I get this working I will be deleting it. Thanks everyone!
12-07-2022 10:27 AM
12-07-2022 10:31 AM
suggestions for your current VI:
use InRangeAndCoerce instead of that pile of comparisons...
use a loop to repeat the same operation multiple times
use RotateArray to get the next three elements...
Suggestion in general: have you considered to use a median filter?
You can also subtract the mean from all sensor values and find the one with greatest difference...
12-07-2022 10:33 AM - edited 12-07-2022 10:34 AM