Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Instrument control

Hi
I have 28 bytes data packet in HEX which are sent from my device at 27 Hz. Each packet carries seven measured values (temperature, voltage, pressure...) in 4 bytes HEX little endain. I want to sort  the 28 bytes HEX in 7 elements array, reverse and then convert them into 32bits floating point. Can you please give some hints how to do that.
 
Thanks
 
0 Kudos
Message 1 of 3
(3,335 Views)
Hi Shimbloo,
 
Thanks for posting on the discussion forums.  One thing you can do is run the array through a for loop, and an inside the for loop use the Reverse String.vi (Functions Palette >> String >> Additional String Function) and then run it into a Hexadecimal String to Number.  It gets converted to a I32.  I hope this helps out.
Regards,

Michael
Applications Engineering
National Instruments
0 Kudos
Message 2 of 3
(3,306 Views)
Thanks for your help , my program is working now
0 Kudos
Message 3 of 3
(3,269 Views)