From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Viewing individual bytes of data

I am trying to read the individual bytes of data from a file format that LabView does not deal with. How Would I open the file and see the numeric vualue of each byte in LabView, if it is even possible?
 
Thanks
 
Beaton
- there is always an easy way, but it is always the hardest to find
0 Kudos
Message 1 of 3
(2,241 Views)
Read the file as a binary data file you can the word size is I16, you can easily convert this to 2 1-Byte words.
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
Message 2 of 3
(2,224 Views)


@Beaton wrote:
I am trying to read the individual bytes of data from a file format that LabView does not deal with.

One way or another, a file is just a long string of bytes. If you know the structure of the file, you can create appropriate code to parse it. Just read the file as a plain string and feed it to "string to byte array", you'll end up with an array where each element is one byte as U8 representation. Just use "index array" to get the element you want. (Of course you could do the same with substring to get one character, then set the display to hex).


 

0 Kudos
Message 3 of 3
(2,215 Views)