VeriStand

cancel
Showing results for 
Search instead for 
Did you mean: 

When is the file transferred to PC complete in a Veristand Data logging Sessions?

Solved!
Go to solution

Hi, 

I am using the NI -Veristand - Start  and Stop Data Logging Sessions to initiate and conclude data saving on a RT target. 

 

 

I noticed that the actual data transfer from RT target to PC is done once the logging has stopped following the call to Stop Data Logging.

stop session.PNG

 

Is there a way to control, or at least check when the data transfer is complete ?

 

I want to read, and possibly dump into another repository the content of the newly created tdms file. For a large file, the transfer may take a few seconds, and presumably my application would have opened the file before it knew the transfer was complete with all the data...

 

I could check the file size of course and see if it keeps changing... but there should be a better way to do this.

 

Thx.

L

 

 

PS: another post on the topic is here, that touches on using UDP for data saving... But it is more for streaming, which is different that what's done in this post's topic.

0 Kudos
Message 1 of 4
(6,261 Views)
Solution
Accepted by LDBM

The API you are referring to streams the data from the targets to be logged directly on the host. The only log files generated are always on the host. Furthermore, after the Stop Logging command completes, you are guaranteed that the log file has been closed and no more data will get logged to it.

Jarrod S.
National Instruments
Message 2 of 4
(6,244 Views)

Ok, great thanks Jarrod.  

 

I must have been fooled then, as I took care to look at the TDMS file size, and it would only show a size different from zero right after the API Stop command is sent. I would acquire for maybe 10-15 sec, with a lot of data just to check... But maybe it is a Windows quirk..


L.

0 Kudos
Message 3 of 4
(6,231 Views)

It is probably the result of internal buffering that takes place as part of the logging operation. When we close the file, we flush any remaining buffered data to disk.

Jarrod S.
National Instruments
0 Kudos
Message 4 of 4
(6,214 Views)