Example Code

Now Its better to transfer data from RT to Host or over Network

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Overview

This example demonstrates data communication over Network, with two VIs as writer and reader respectively.

 

Description

In LabVIEW 2010 National Instruments introduce the new data communication technique called Network Stream. This function addresses some major issues with data communication over TCP/IP.

Now to transfer the data no need to flatten data, count the bytes and again unflatten the data. Now you can transfer any type of data over Network without extra efforts and coding.


Requirements

  • LabVIEW 2012 (or compatible)

 

Steps to Implement or Execute Code

  1. Download the attached ZIP file or the Write and Read VIs.
  2. Open and Run  Network Stream Write (2012).vi
  3. Open and Run Network Stream Read (2012).vi
  4. Rotate the Knob in Write VI to control the frequency of transmitting signal and view the signal in Read VI.

 

Additional Information or References

Front Panel of writer and reader

1.png

 

VI Snippet of Network Stream Write (2012).vi

writer.png

 

VI Snippet of Network Stream Read (2012).vi

reader.png

 

 

**This document has been updated to meet the current required format for the NI Code Exchange.** 

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.