LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview TCP/IP

Hello all, I am attempting to stream data over TCP/IP to a raspberry Pi. I have posted about this previously but have made some changes so here is a new post. My goal is to send 1-second block of data to TCP/IP. I am sampling two (2) channels at 100khz with a NI-9215 and getting a timestamp with a NI-9467. On FPGA_Main I am triggering an interrupt every 100K cycles to be able to send the time stamp every theoretical second. In Playaround in the bottom loop I am writing the data over TCP/IP every time a notification arrives, but I believe the loop in which I streaming data over TCP/IP is happening to quickly for the complete 1-second block of data to be sent. The end goal is to send a time-stamp, an associated offset_from_time_reference, and 100k samples for both channels over TCP/IP. The only two VI of concern is the FPGA_Main.VI and the Playaround.VI. 

wsimpson0050_0-1771517784768.pngwsimpson0050_1-1771517850002.png

 

0 Kudos
Message 1 of 3
(200 Views)

I am going to change my question. I have changed a little on my main RT VI (the Playaround.VI) and would like to know how can build array or something similar that contains following in order:

 

1st: the timestamp and offset string in loop two

2nd: 100K samples from both channels (so really 200k) 

 

I am sampling at 100KHz so I would like to build a 1-second chunk of data and then send it over TCP. 

Thanks for any help.  

 
 

 

0 Kudos
Message 2 of 3
(87 Views)

Hi wsimpson0050,

Why not use cluster as you see fit? Flatten cluster to string, send this string over TCP/IP and then decode that string on PI. 


@GerdW talked about something similar in this post: https://forums.ni.com/t5/LabVIEW/Read-binary-dump-of-LabVIEW-cluster-from-Python/td-p/4136832
Hex display string.pngFlatten cluster to string.png

0 Kudos
Message 3 of 3
(45 Views)