06-13-2009 12:52 PM
I'm working with the VI from a Hantek DSO-2150 USB oscilloscope. LabVIEW shows the data in a graph but I'd like to output the results to a CSV file. I think the "Write to measurement file" control would be of use but I'm not sure how to use it. Would someone please help a newbie?
Thanks!
06-13-2009 03:13 PM
I did not see File I/O happen anywhere. Have you given it a shot at all? For your case, I would recommend using the Write to Spreadsheet File node.
Also, have a look at Fundamentals -> File Input and Output in the Example Finder (Help -> Find Examples) to look at some examples.
And, I would recommend that you change your architecture. Using Flat Sequence Structures is not the right way to program an application in LabVIEW. I would recommend you have a look at the State Machine Design Pattern (File -> New..) and consider that architecture so it can help you avoid issues in the future as your application grows larger.
06-13-2009 03:57 PM
06-13-2009 04:05 PM
06-13-2009 04:20 PM
Thanks Adnan, the state machine sounds like an excellent idea. I am working with an oscilloscope and their software is somewhat lacking. One problem now is it takes 30,000 samples, writes it to file, and then takes 30,000 again. Could this be a limitation of the scope? I'd like to have "seamless data logging".
Thanks again for all of your help!
06-13-2009 04:52 PM
06-13-2009 04:59 PM
06-13-2009 10:40 PM
And just to answer your original question:
The 'write to spreadsheet file' has an input for 'delimeter'.
By default, the delimiter is 'tab' but you can wire a ',' and it will use a comma as a delimeter.
Then if you save the file as *.csv excel should be able to open it no problem.