Storing and Accessing Data From Different Parts of an FPGA Design
- Updated2025-09-18
- 6 minute(s) read
To store data using an FPGA application when you need to access that data from multiple clock domains, select from the following options:
| Method | Use case |
|---|---|
| Register items |
|
| Memory items implemented using block memory |
|
| Handshake items |
|
Register Items
Use register items to store data when you need to access that data from multiple clock domains or from different parts of your design and you need to write reusable code. Register items consume fewer FPGA resources than FIFOs, and they do not consume block memory, which is a limited type of FPGA resource.
The LabVIEW FPGA Module has two types of register items:
- VI-defined register items: Use VI-defined register items to create reentrant subVIs and avoid resource conflicts. If you configure a VI-defined register item in a reentrant FPGA VI, LabVIEW creates a separate copy of the register item for each instance of the VI.
- Target-scoped register items: Use target-scoped register items if you want the register item to be visible and configurable from the Project Explorer window. Target-scoped register items are available within any FPGA VI under the same target in the Project Explorer window.
The following block diagram shows how you can read from and write to a register item using a Register Method Node configured for a target-scoped register item. This VI adds the value of two controls, X and Y, writes the sum to a register item, reads the stored value, increments the stored value, and prints the result to an indicator. Note that the Write and Read methods are in two different clock domains.
Creating a Target-Scoped Register Item from the Project Explorer Window
Complete the following steps to create a target-scoped register item from the Project Explorer window.
- In the Project Explorer window, right-click the FPGA target.
- Select New»Register to display the FPGA Register Properties dialog box.
- Click OK to finish creating the register item.
- Drag the register item from the Project Explorer window to the block diagram. LabVIEW adds a Register Method Node configured for the register item.
Creating a Register Item from the Block Diagram
You can create either a target-scoped or a VI-defined register item from the block diagram.
Target-Scoped:
- Display the block diagram of the FPGA VI.
- From the Functions palette, add a Register Method Node to the block diagram.
- Right-click the Register Method Node and select Add New
Register to display the FPGA Register
Properties dialog box.

Tip You also can right-click the Register Method Node and select Select Register»x, where x is an existing register item. - Click OK to finish creating the register item.
You also can wire a reference to the Register In input to specify an existing register item. LabVIEW configures the Register Method Node with the default method, Write. After you specify the register item, right-click the Register Method Node and select Select Method»y, where y is the specific method.
VI-Defined:
- Display the block diagram of the FPGA VI.
- From the Functions palette, add a VI-Defined Register Configuration Node to the block diagram.
- Right click the VI-Defined Register Configuration Node and select Configure to display the FPGA Register Properties dialog box.
- Click OK to finish creating the register item.
Handshake Items
Handshake items behave like single-element FIFOs. Use handshake items to transfer one data element between a writer node in one clock domain and a reader node in the same or a different clock domain. Use handshake items to achieve lossless transfer from a writing domain to a reading domain and notify the writing domain when the reader receives the data. Handshake items consume fewer FPGA resources than FIFOs, and they do not consume block memory, which is a limited type of FPGA resource.
The LabVIEW FPGA Module has two types of handshake items:
- VI-defined handshake items: Use VI-defined handshake items to create reentrant subVIs and avoid resource conflicts. If you configure a VI-defined handshake item in a reentrant FPGA VI, LabVIEW creates a separate copy of the handshake item for each instance of the VI.
- Target-scoped handshake items: Use target-scoped handshake items if you want the handshake item to be visible and configurable from the Project Explorer window. Target-scoped handshake items are available within any FPGA VI under the same target in the Project Explorer window.
Reading Data Using a Handshake Method Node
There are two ways to read data using a Handshake Method Node:
| Method | Use case |
|---|---|
| Read method |
|
| Acknowledge and Read Without Acknowledge methods |
|
The following block diagram shows how you can read from and write to a handshake item using a Handshake Method Node configured for a target-scoped handshake item. This VI increments a value by one, writes the data to a handshake item, reads the stored value, and automatically acknowledges the read. Input Valid is TRUE when Ready for Input is TRUE. The VI then writes the stored value to an indicator when Output Valid is TRUE. Note that the Write method and the Read method are in two different clock domains, indicated by two red boxes. This design ensures lossless data transfer by writing all data points to the faster clock domain.
Creating a Target-Scoped Handshake Item from the Project Explorer Window
Complete the following steps to create a target-scoped handshake item from the Project Explorer window:
- In the Project Explorer window, right-click the FPGA target.
- Select New»Handshake to display the FPGA Handshake Properties dialog box. Use the options in this dialog box to configure the handshake item.
- Click OK to finish creating the handshake item.
- Drag the handshake item from the Project Explorer window to the block diagram. LabVIEW adds a Handshake Method Node configured for the handshake item.
Creating a Handshake Item from the Block Diagram
You can create either a target-scoped or a VI-defined handshake item from the block diagram.
Target-Scoped:
- Display the block diagram of the FPGA VI.
- Add a Handshake Method Node to the block diagram.
- Right-click the Handshake Method Node and select Add New
Handshake to display the FPGA Handshake
Properties dialog box.

Tip You also can right-click the Handshake Method Node and select Select Handshake»x, where x is an existing handshake item. - Click OK to finish creating the handshake item.
You also can wire a reference to the Handshake In input to specify the handshake item. LabVIEW configures the Handshake Method Node with the default method, Write. After you specify the handshake item, right-click the Handshake Method Node and select Select Method»y, where y is the specific method.
VI-Defined:
- Display the block diagram of the FPGA VI.
- Add a Handshake Method Node to the block diagram.
- Double-click the VI-Defined Handshake Configuration Node to display the FPGA Handshake Properties dialog box.
- Click OK to finish creating the handshake item.