LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Record changes to array elements for certain values condition (historical data).

I have an array of clusters, cluster contains a name and status (string value of Pass or Fail).  I would like to create a copy of the array that stores changes to any element when it the status is Fail.  The value in this historical array should only change from Pass to Fail (first time element fails, data is stored and cannot be changed).  This historical array shall keep a record of any element failure regardless if it has cleared itself (return to a Pass status).  This historical array can be cleared by user hitting a reset button (all statuses return to Pass).

I have tried using a case structure looking for a Fail status and writing the element to a copy of the original array, however only the Fail elements are being passed.  Wiring for the Pass condition causes the historical array to be updated back to Pass. 
0 Kudos
Message 1 of 4
(2,743 Views)
I must admit that your query was not clearly understood by me.
 
Probably, you could post the VI you have developed to do this check. We could have a look at it and suggest better.
 
The Pointers i could give would be: Are you using a shift register to store your array of cluster's values from previous iteration??
And passing/wiring it through both the case conditions??
0 Kudos
Message 2 of 4
(2,724 Views)
Jac,

Devchander has a good idea about using shift registers.  Another thing you might want to try is having some sort of visual display representing your arrays on your front panel and put together a VI just to test the use of the cluster array.  This might help pinpoint any errors.


TheDillo
0 Kudos
Message 3 of 4
(2,718 Views)
Thanks for the suggestions. I am still working on this problem but as with most software applications, this feature may not be within the defined requirements. 

I realized that since I am continuously communicating with a serial device, constantly logging the failures would also log the same failure at every iteration (wasting memory).  I will have to incorporate checking the previous state in order to log the failure only when it first occurs.


0 Kudos
Message 4 of 4
(2,715 Views)