LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Should I implement a lookup table?

I'm running a test that requires me to output an N-bit word and input a 50-bit boolean array which I need to compare to the expected 50-bit boolean array. 

 

How should I implement storing these "expected boolean arrays" for easy comparison in my 'pass/fail' subvi?  

 

 

0 Kudos
Message 1 of 4
(2,495 Views)

If you have more than just a very few arrays or if they will change from time to time, store the arrays in a configuration file. There are VIs in the File palette specifically designed for managing configuration files.  Look at the help and examples for more information.

 

The program would read the configuration file at startup (and as required while running) and load the 50-bit arrays.

 

Lynn

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

I would probably store them as attributes of a varient (saved to an xml file) and create an editor for the file as well so when one array changes...... you don't need to rewrite the BD constant


"Should be" isn't "Is" -Jay
0 Kudos
Message 3 of 4
(2,486 Views)

@LennyBogzy wrote:

I'm running a test that requires me to output an N-bit word and input a 50-bit boolean array which I need to compare to the expected 50-bit boolean array. 

 

How should I implement storing these "expected boolean arrays" for easy comparison in my 'pass/fail' subvi?  

 

 


Store it as an U64, then convert to bool array in the program.

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
Message 4 of 4
(2,476 Views)