LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Reading and writing hexidecimal value

I am pulling a string of HEX data from a file, I want it to remain HEX data to send out of a VI.  When I get this data out from the file, even though it is in HEX it is HEX displayed in ASCII, so when I then convert the datatype to HEX I have values which are completely changed.  I can't figure out a way to convert this back into the proper data, or to set the output of the open file function to "hex".  I have tried typecasting it into a HEX string (that made sense to me!) and converting it into a byte aray but could not find a solution.  Is there a way to display data in HEX?  See attached below. The file to open is also attached. 
 
 
 
Download All
0 Kudos
Message 1 of 3
(2,953 Views)
I am confused by your terminology.
 
It seems your file is ASCII formatted text with a comma as delimiter and two characters (0...F) for each value. If you want to convert this as a pure hexadecimal string, you could use "spreadsheet string to array with %x as format and "," as delimiter and a 1D U8 array as type. Now just use "byte array to string" to make your string.
 
Is that what you want?
Message 2 of 3
(2,948 Views)

I am confused by my terminology also!  This worked perfectly, thank you for the response.

 

 

Andrew

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