LabVIEW MathScript RT Module

cancel
Showing results for 
Search instead for 
Did you mean: 

Identify a null character in MathScript

I have a script that reads in binary data from a file, but there are null characters separating each entry. What syntax does MathScript use for the null character??

 

The script is something like this:

 

entry = fread(fid, 1, 'uchar');
if entry ~= NULL                     

     column = [column entry];
else                                         %When we hit a null, we finished one column title, then cycle until we begin another one.

     ... Do other stuff....;

0 Kudos
Message 1 of 2
(6,148 Views)

If you're reading a binary file and searching for a Null character, I would assume that it would be represented as the binary equivilent of the ASCII NULL Character, which would be 00000000.

 

Otherwise, if you are using the MathScript Node in LabVIEW, it will use the same NULL character that LabVIEW uses, '\0'

 

 

Logan H

National Instruments
Applications Engineer
0 Kudos
Message 2 of 2
(6,136 Views)