LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

problem during conversion

Hi,

     In the attached VI,Iam giving temperature input from a string array,then converting it to binary and again converting to a decimal inorder to display in the thermometer.But while running it is giving incorrect values.what to do with this VI??

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks as kudos only:)
0 Kudos
Message 1 of 6
(2,820 Views)

Where the temperature comes from and why is it in an array?

I'm not sure the code below is what you need, but what I'm pretty sure about is that you use too many conversion operation, only one should be enough.

 

 

Hex to Binary 64 bit (LV 8+) (1)_BD.png

 

Hope this helps


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

0 Kudos
Message 2 of 6
(2,815 Views)

Hi Tito,

          You have given a simple display.But Iam trying to pack them in a particular frame.That's why Iam trying to convert it to binary and then reconverting it and displaying.My VI works fine when Iam entering numbers below 10(Ah).So please give some suggestions in that way.

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks as kudos only:)
0 Kudos
Message 3 of 6
(2,808 Views)

Hi Danil,

 

again you created a new thread instead of sticking with the original one. I think I recommended more than once to not create double posts. All you do is creating irritated users as others don't know the origins of your VI examples. DON'T CREATE DOUBLE POSTS!!!

 

You also didn't learn to write good questions: "My VI works fine when Iam entering numbers below 10(Ah)"

 

What does not work?

Which results are wrong/unexpected?

Which results do you expect?

Can't you give good examples?

 

Your VI also works for "numbers" greater than 10, for instance "10" (hex) gets converted to 16 (decimal).

The VI is limited to U8 values (00 to FF in hex), which allows 0 to 255 in decimal...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 6
(2,799 Views)

Sorry,

         I mean,when I enter 50.The thermometer indicates 80.That result is unexpected.Inorder to get 50 as 50,what have to be changed in the VI?

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks as kudos only:)
0 Kudos
Message 5 of 6
(2,789 Views)

Hi Danil,

 

in your example VI you used (and always wanted to use, as is clearly written in the first message of you original thread as linked before) the function "Hexadecimal string to Number". Now you wonder why a string of "50" is converted to a (decimal) number of 80???

 

Come on, sometimes it really helps to read the context help for all the functions used, even for such a small VI...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 6
(2,783 Views)