06-05-2012 05:36 AM
Hello Friends,
I have to convert Numeric to String to send in MODBUS Communication. I dono the conversion so that numeric can be made variable and i will do conversion internally. Pls have a look at the VI attached to get clear idea. If you still have doubt in this I am ready to explain.
Thanks and Regards,
Ratheendiranaath B.R.
Solved! Go to Solution.
06-05-2012 05:42 AM - edited 06-05-2012 05:42 AM
Hi friend,
- "to/from hex conversion" is ask very often in the forum. Did you read any of those threads?
- You also don't give clear explanations: In your example you convert your input 12 to a string displaying "12" in hex mode. Do you really want to have BCD numbers in the string? Or do you expect "0C" as string (in hex display mode)?
- using DBLs to convert to string is also ambigous. Do you wnat the value converted to some integer format or do you want to typecast the DBL?
06-05-2012 06:03 AM
Yes. I want to convert that numeric input into BCD numbers what we enter in String constant in Hex Display.
06-05-2012 06:17 AM - edited 06-05-2012 06:18 AM
06-05-2012 06:29 AM
This is what i was expecting. Thanks for your help.
Ratheendiranaath
🙂
06-06-2012 12:04 AM
Hello,
In order to inter-convert data types, LabVIEW provides in-built conversion palettes. For example, in order to convert numeric to string (decimal, hex display, etc), you can have a look at the following palette:
Programming>>String>>String/Number conversion
You may find some useful functions there. Hope this helped!