06-19-2025 12:40 PM - edited 06-19-2025 01:02 PM
Here's some code showing two alternatives (It is possible that it is I16, so adjust accordingly):
Most likely all other bytes in the string also have meaning and if you know the entire structure you can cast it to a cluster with all the values at once. (not shown).
Do you have documentation?
On a side note, none of this has anything to do with "hexadecimal to decimal conversion" (sic). You have 2 bytes in a string and need to reinterpret it as 2 byte numeric integer datatype. Hexadecimal and decimal are a formatting convention to display values in a certain readable format. using ASCII characters 0..9 or 0..F. You can change the display format of the numeric indicators to hex, octal, binary, or decimal and this will not change the underlying value of it!
06-19-2025 12:54 PM
Hi Knight of NI,
You answered my question. I have an instrument that I query, and it always returns a frame with the same amount of data. Your answers helped me solve my problem. Thank you very much!
06-20-2025 03:48 AM
Hello,
perhaps this in general can help you with these kind of conversion: