LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Save data at given simple rate with new file name

Hi,

 

I'm using a PXI-5105 scope to acquire data generated by a function generator. Currently I am able to save the data displayed by the scope under a given name: test.txt

 

What I would like to do is continously save the acquired data at a given sample rate under a new file name. In other words, when I first "turn on" the boolean switch, a first set of data is saved as test001.txt, 1 second later the new incoming data is saved as test002.txt and so on.

 

I looked into this a couple weeks ago and thought I had found a VI posted by another user that did exatcly this, but I can't seem to find it anymore.

 

I attached the VI I'm using to save the data. I'm still relatively new to LabVIEW, so my program isn't as efficient as it can be. I'm in the process of changing the program so the two switches don't conflict.

 

Any help would be greatly appreciated.

 

Best,

Marc

0 Kudos
Message 1 of 5
(2,432 Views)

I forgot to attach the file. Here it is.

0 Kudos
Message 2 of 5
(2,431 Views)

Hello!

 

I found an example VI that coutinuously reads and writes data.  Maybe this is the example you were looking for.  Let me know how this helps!

 

http://zone.ni.com/devzone/cda/epd/p/id/284

 

Also, possibly replace your inside case structure with a while loop and a timer inside the while loop.  This will also continuously read and write.

 

Regards,

Cody C

0 Kudos
Message 3 of 5
(2,399 Views)

Hi Cody,

 

Thanks for responding.

 

This VI is not the one I've seen previously, but it may work. However there are missing several subVIs which has already been noticed by another user judging by the comments (dating back from 2006). Any chance you know where I could find these VIs?

 

Marc

0 Kudos
Message 4 of 5
(2,393 Views)

The missing subVI's are ones from the traditional DAQ driver (as noted in the requirements of the article) which no one intalls anymore unless they absolutely need them.  They should be replaced with DAQmx subVI's.

 

If you decide to look at the example, be sure to run a diagram cleanup on it.  For some reason, many of the functions are laying on top of each other.

0 Kudos
Message 5 of 5
(2,388 Views)