LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

changing bit resolution

Well, typically you want to scale the DBL data because once you convert to integer, you'll discard all fractional parts.

 

All your blue wires are integers, so placing small fractional scales on the graph will not do you any good anyway.

 

Maybe you want to do FXP datatype?

 

(I cannot download your megaupload, most likely or firewall prohibits it.)

Message Edited by altenbach on 09-03-2008 04:23 PM
0 Kudos
Message 11 of 15
(972 Views)

OK, try something like the following:

 

 

0 Kudos
Message 12 of 15
(947 Views)

Awesome!  This works.  So to see if I understand, you scaled the input data by a power of 2 raised to the 22 (arbitrary) to get a good sized signal, then converted it to 16 bits, and then readjusted the y-axis levels to make it fit..

 

Would you happen to know why converting to 16 bits have that affect on the input signal that you have to scale it by a power of 2^big?

 

You're a big help.  Thanks Smiley Happy

0 Kudos
Message 13 of 15
(941 Views)
Also, its possible to rescale the input signal with any large number, am I correct? 🙂  Thanks!
0 Kudos
Message 14 of 15
(940 Views)

If your data is I16, it is an integer, so the smallest increment is 1. You cannot have any fractions! An I16 number can cover all whole numbers in the range -32768 to 32767, so to make most efficient use of all bits, you should make sure that your highest absolute value in your DBL array scales near (but below) 32767.

 

For the graph display, you might want to adjust x0 and dx of the y axis so it scales back to the original numbers. It's a simple linear transformation.

 


Jud~ wrote: 

Would you happen to know why converting to 16 bits have that affect on the input signal that you have to scale it by a power of 2^big?


 

 Your original numbers are very small (<<1!), so there is no way to direct convert them to I16, you would get all zeroes.

0 Kudos
Message 15 of 15
(927 Views)