To download NI software, including the products shown below, visit ni.com/downloads.
Overview
The example demonstrates how to convert a R-Series I/O raw value to a fixed point value.
Description
There are two analog I/O data types available for use, depending on your FPGA target. If you use a PCI/PCIe/PXI/PXIe R Series target, the analog I/O data type is either an I16 or an I32, depending on the device. These devices return uncalibrated data. If you use a CompactRIO target or USB R Series target, then the default data type is fixed-point and the data has been calibrated. You can, however, choose to configure the module to return raw integer data as well.
If the FPGA device does not support calibrated data (fixed-point representation) the uncalibrated data has to be often converted from an integer to a fixed-point representation e.g. to perform analysis operations. In control application with little allowed latency that conversion has to be performed on the FPGA. The example demonstrates how to do the conversation from uncalibrated integer data to fixed-point data.
Requirements
Software
Hardware
Steps to Implement or Execute Code
Additional Information or References
Working With Calibrated and Uncalibrated Data on NI R Series
**The code for this example has been edited to meet the new Community Example Style Guidelines. The edited copy is marked with the text 'NIVerified'. Read here for more information about the new Example Guidelines and Community Platform.**
Description-Separate-2Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.