Data Communication Methods in LabVIEW
- Updated2025-08-15
- 5 minute(s) read
LabVIEW contains many data communication methods, each suited for a certain use case. To ensure you implement the correct data communication method for your application, refer to the overview presented in this topic. For detailed information about a particular data communication method, click the title of the data communication method you want to learn more about.
| Data Communication Type: | Dataflow Elements | Buffer Interfaces | Variable Interfaces |
|---|---|---|---|
| Use Case: | Sending data between most block diagram objects. | Sending data between locations when it is important to avoid overwriting or losing any value. | Storing a readily-accessible value in memory where the latest value is of primary interest. Use carefully to avoid race conditions. |
| Examples: | Passing data from a VI output to a VI input. | Acquiring a waveform; sending a message or command; streaming an image. | Monitoring the current temperature; monitoring the system state. |
| Categories: | — Wire — Shift register — Feedback Node — Channel Wire | — Queue — RT FIFO — User events — Asynchronous Message Communication (AMC) Reference Library — Network streams — TCP — Simple TCP Messaging (STM) Reference Library — Target-scoped FIFO — VI-defined FIFO — DRAM — DMA FIFO — Peer-to-Peer (P2P) FIFO | — Local variable — Global variable — Functional global variable (FGV) — Single-process shared variable — Data value reference — Current Value Table (CVT) — Network-published shared variable — Programmatic Shared Variable API — Web services — UDP — Global variable — Memory item — Register item — Read/Write Control — NI Scan Engine and Variables — User-defined I/O variable |
Dataflow Elements
To take advantage of the dataflow programming environment in LabVIEW, you should use wires, shift registers, feedback nodes, and channel wires as the primary data communication methods in your application.
| Method | Attributes |
|---|---|
| Wire |
|
| Shift register |
|
| Feedback Node |
|
| Channel Wire |
|
Buffer Interfaces
Use buffer interfaces when you must send data from one location to another and you do not want to overwrite or lose any value. A buffer interface is often represented as a FIFO (first-in, first-out) single or multi-element buffer where one or more writers add data onto one end of the buffer and a reader retrieves data from the other end.
Intra-Target or PC
| Method | Attributes |
|---|---|
| Queue |
|
| RT FIFO (Real-Time Module) |
|
| User events |
|
| Asynchronous Messaging Communication (AMC) Library
(Available at ni.com) |
|
Networked
| Method | Attributes |
|---|---|
| Network streams |
|
| TCP |
|
| Simple TCP Messaging (STM) Reference Library
(Available at ni.com |
|
Intra-FPGA
| Method | Attributes |
|---|---|
| Target-scoped FIFO (FPGA Module) |
|
| VI-defined FIFO (FPGA Module) |
|
| DRAM (FPGA Module) |
|
FPGA to/from Host
| Method | Attributes |
|---|---|
| DMA FIFO (FPGA Module) |
|
FPGA to FPGA
| Method | Attributes |
|---|---|
| Peer-to-Peer (P2P) FIFO (FPGA Module) |
|
Variable Interfaces
Use variable interfaces when you must store a value in memory that readers and writers can access with minimal or no flow control. Note that you should use variables in cases where the latest value is of primary interest and it is acceptable to overwrite previous values. Use carefully to avoid race conditions.
Intra-Target or PC
| Method | Attributes |
|---|---|
| Local variable |
|
| Global variable |
|
| Functional global variable (FGV) |
|
| Single-process shared variable |
|
| Data value reference |
|
| Current Value Table (CVT)
(Available at ni.com |
|
Networked
| Method | Attributes |
|---|---|
| Network-published shared variable |
|
| Programmatic Shared Variable API |
|
| Web services |
|
| UDP |
|
Intra-FPGA
| Method | Attributes |
|---|---|
| Global variable |
|
| Memory item (FPGA Module) |
|
| Register item (FPGA Module) |
|
FPGA to/from Host
| Method | Attributes |
|---|---|
| Read/Write Control (FPGA Module) |
|
|
NI Scan Engine and Variables
(FPGA Module + NI Scan Engine support on your target) |
|
| User-defined I/O variable (FPGA Module) |
|