08-01-2017 03:37 PM
In my application, I am attempting to stream live data to a TDMS file. In short runs, there is no problem. However, if I run it for too long (10-15 minutes), I get error code -2500 at the TDMS Write function, with "Storage VI's internal error" listed as a possible reason.
I've attached screenshot of the section of code where the error is occurring. If anybody has seen this error code before or has an idea of what might be causing it, please let me know.
Thanks,
Brandon
08-01-2017 03:51 PM - edited 08-01-2017 04:02 PM
Its pretty hard to tell exactly what the hidden code is doing but, in general I would change your approach somewhat. But it looks like for Each Group, you choose weather or not to write data for each channel and write the channels one at a time
Try collecting the Data, and Channel Names in arrays then in the inner loop and write all selected channels data PER Group to the TDMS file.
In fact, it looks like your "Stress Data" has an "Interleaved" data layout so you could probably "Get Array subsets" and use conditional tunnels to select enabled channels and data.
If you save some "Default Data" and post the actual vi,and a small section of an example TDMS we can probably get that vi down to the size of a postage stamp.
08-02-2017 08:16 AM
I found this which *may* be related to your issue:
http://digital.ni.com/public.nsf/allkb/8E57CA5AEB3D88B5862575B60063BA2A
http://zone.ni.com/reference/en-XX/help/371361L-01/lvconcepts/fileio_tdms_file_buffering/
If possible, uploading your code may make debugging slightly easier. It's a little hard to tell 100% what is going on from the screenshot.
08-02-2017 08:44 AM
Here is a slightly modified version of the code. The screenshot I posted before was of a sub VI that is placed inside of a loop in the main block diagram, which runs at up to 1000 Hz. The input data is an array where the first 70 elements come from rosette strain gauges and the last 10 come from single strain gauges.
I also attached an example of what the file might end up looking like.
08-02-2017 09:47 AM
You may want to consider wiring the error cluster through your program and out to a simple error handler to better isolate the issue as a first step. I will try to look into this further.
08-02-2017 11:35 AM
I just tested the previously posted section of code having added a section to manually set the NI_MinumumBufferSize property for each channel. Doing so allowed the program to run for over an hour (4 times longer than before) before crashing. I also observed that the size of the TDMS and index files was significantly reduced.
Do you have a recommendation for how big to set the buffer for each channel? In this case I used 1000.