Introduction to the FPGA Interface C API

Publish Date: Sep 27, 2017 | 5 Ratings | 4.20 out of 5 | Print

Overview

The FPGA Interface C API is a C API for communication between processor and FPGA within NI reconfigurable I/O (RIO) hardware such as NI CompactRIO, NI Single-Board RIO, NI Ethernet RIO, NI FlexRIO, NI R Series multifunction RIO, and NI MXI-Express RIO for embedded control and acquisition applications.

With the FPGA Interface C API, developers can use LabVIEW graphical tools to program the field-programmable gate array (FPGA) within NI hardware and choose either LabVIEW or C/C++ tools to program the processor within the system. This gives engineers and scientists with C expertise the ability to take advantage of FPGAs within their designs without the burden of learning hardware design while also giving them the option to reuse their existing embedded C code.

Table of Contents

  1. FPGA Interface C API
  2. Using the FPGA Interface C API
  3. Download Required Software
  4. Learn More

1. FPGA Interface C API

With the FPGA Interface C API, engineers and scientists can program the real-time processor on NI FPGA-based hardware using C tools such as NI LabWindows/CVI, Microsoft Visual Studio, Eclipse, Wind River Workbench or the GNU GCC toolchain and interface to the LabVIEW FPGA code running on the FPGA. Developers also can program the processor using the LabVIEW Real-Time Module, which includes tools for low-level system debugging and precision execution timing for increased flexibility and functionality of deterministic real-time applications.

Figure 2.  Choose a C/C++ development environment based on which hardware platform and operating system meets your application requirements.

The FPGA Interface C API includes nearly all the same functionality as the existing LabVIEW host interface, including the ability to read and write FPGA front panel controls, target-to-host and host-to-target DMA streaming, and IRQ assertion and acknowledgement. 

 

Back to Top

2. Using the FPGA Interface C API

The following steps outline the development process. For detailed instructions, refer to the FPGA Interface C API Help documentation:

  1. Develop and compile your LabVIEW FPGA VI. This produces a bitfile.
  2. Launch the FPGA Interface C API generator. Based on the bitfile, a C header file is generated.
  3. Include the header file in your C/C++ application.
  4. Build and deploy the application to the embedded target.

 

Back to Top

3. Download Required Software

Required software for FPGA development:

  1. LabVIEW (Full or above)
  2. LabVIEW FPGA Module
  3. NI RIO Device Drivers

Required software for C application development:

  1.  FPGA C Interface API

Optional software for application development

  1. LabWindows/CVI ANSI C IDE
  2. LabWindows/CVI Real-Time Module
  3. LabVIEW Real-Time Module

 

Back to Top

4. Learn More

» View the tutorial for building a FPGA host application in LabWindows™/CVI

» Access the FPGA Interface C API Help Documentation

» Learn more about C/C++ Embedded System Design Tools

» Learn more about NI R Series multifunction RIO

 

Back to Top

Bookmark & Share


Ratings

Rate this document

Answered Your Question?
Yes No

Submit