LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

float to bytes conversion using labview

Solved!
Go to solution

in university project i want to transmit  float number serialy using labview. i dont know how to convert float into its individual bytes actualy i want to encode float in to its bytes. kindly help me about that

0 Kudos
Message 1 of 20
(5,069 Views)
Use the type cast function and wire an array of u8 to the type specifier. That should work for you. You will get 8 u8's in the array.
0 Kudos
Message 2 of 20
(5,048 Views)

i m a new user of labview kindly can u give me a block diagram of it. for example l want to convert 18.25 to its 4 bytes and then want to send it serialy in labview how can i do that? i shal be very thankful to u sir for this help

0 Kudos
Message 3 of 20
(5,036 Views)
Solution
Accepted by topic author ranazeeshanali

Sending "bytes" is typically done in the form of strings. SImply use typecast with the type input disconnected (or use "flatten to string").

 

To get started, easiest would be to use the example finder in LabVIEW and look for serial communications.

0 Kudos
Message 4 of 20
(5,002 Views)

thnx  sir can u give me the block diagram plz

0 Kudos
Message 5 of 20
(4,992 Views)
Just use the search button on the function palette.
0 Kudos
Message 6 of 20
(4,985 Views)

help...find examples...search for "serial".

0 Kudos
Message 7 of 20
(4,980 Views)

how to recover float number from its bytes then?

0 Kudos
Message 8 of 20
(4,971 Views)
So you want to be spoon fed? Maybe try a function like type cast!
0 Kudos
Message 9 of 20
(4,964 Views)

Why don't you do everyone a favor and try to put something together and show us what you got?  If you skate now, we all pay later.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 10 of 20
(4,943 Views)