4 Byte Decimal

Lars Bolduc 1 year ago in IQANdesign updated by Gustav Widén (System support) 1 year ago 3


I'm pretty confused about something.

Right now I have a single 4 Byte JPIN with a dedicated JFIN.

Image 3522

Standard 1 resolution per bit with no offset.

And I'm displaying it with an unlimited Value Control with automatic width.

32 bits should go up to 4,294,967,295 (0xFFFFFFFF).

The highest I can slide the slider in IQANsimulate is 2,115,669,120 (0x7E1A8C80).

And the highest that will be displayed in the Value Control is 2,000,000,000 (0x77359400).

Image 3520

Image 3521

Is this a limitation of the simulator, and it'll work fine on the machine?

Or is it a real limitation of the JFIN/JPIN?


The Value Control must be a bi-directional integer with 2x10^9 maximum.

Splitting the 4 bytes into 2x2 bytes allows the JFINs to capture all the data.

I can display the bottom 2 bytes easily in one Value Control.

But without array operations (concatenate, bit shift, etc) I'm not sure how I'm going to cut out the top 2 bytes and display them.

I got so close, but I ran into the 7 significant figures available to the real type.

A 32-bit decimal has 10 sig figs and no math can be done on them.

I'll just have to display it in HEX and have the user calculate it into decimal.


I just posted my functions for manipulating precision Lat/Long position data. The display function takes the 2 16-bit values and displays them as a coordinate with 7 decimal places (10 significant figures). You should be able to adjust this function by placing the decimal point wherever you need it in the text formatting function (and changing the units). Link to the post below