Archived: Using Fixed-Point Data Types with Integer-Based IP in LabVIEW FPGA 8.5.x and 8.6.xThis document has been archived and is no longer updated by National Instruments
Primary Software Version: 8.5
Primary Software Fixed Version: N/A
Secondary Software: N/A
How can I use fixed-point data with LabVIEW FPGA Math and Analysis functions that support only integer data in Labview FPGA Module 8.5.x and 8.6.x?
In LabVIEW 8.5.x and 8.6.x, the LabVIEW FPGA Math and Analysis functions support only integer data types. If a fixed-point number is passed directly to a function, LabVIEW truncates the fractional portion when the number is coerced to an integer.
To use fixed-point data with integer IP, you must sign extend the fixed-point data by increasing the integer word length to the size of the integer used. The steps below detail the method to pass a fixed-point number as an integer to the DC and RMS Measurements Express VI, which uses an I16 data type.
Note: To ensure the Number to Boolean Array function uses arrays of fixed dimensions you must select VI Properties, select Execution and place a checkmark in the Autopreallocate arrays and strings checkbox.
Fixed-Point to Integer Conversion
Integer to Fixed-Point Conversion
Additionally, in newer versions of LabVIEW FPGA Module, the Math and Analysis functions directly support fixed point data.
KnowledgeBase 4DPGKPKO: How Can I Transfer My Fixed-Point Data Using a FIFO or Memory in LabVIEW 8.5.x?
KnowledgeBase 4FSHBMLX: Using Fixed-Point Data with CompactRIO and LabVIEW FPGA
FXP to Legacy IP_85.zip
FXP to Legacy IP 2009.zip
FXP to Legacy IP.png
Report Date: 03/17/2008
Last Updated: 04/22/2015
Document ID: 4JGA2HLX