Measurement Studio for VC++

cancel
Showing results for 
Search instead for 
Did you mean: 

How to save data acquired from NI-DAQ in text format instead of TDMS using the DAQ-mx ANSI C code?

Hi,

 

I wanted to save data acquired from NI-DAQ (for example, NI 9234) in a file using the DAQ-mx ANSI C Code. The response I got was as follows:-

 

One way to do it is with TDMS logging. DAQmx comes with functions designed to log to a TDMS file. This is a special file type that is used for collecting data in a logical format. It can be displayed in a TDMS viewer where data is separated into groups and channels. NI-DAQmx provides examples for how to log to TDMS. Look at the TDMS examples in the C:\Users\Public\Documents\National Instruments\NI-DAQ\Examples\DAQmx ANSI C\Analog In\Measure Voltage directory.

 

However, now I want to know is there a way that using that same C code, can we save the data in a .txt file format (Text File) instead of a TDMS file? We actually want to access that file through MATLAB (that's why we want to save it in text format).

 

Also on an other note, is there a way we can access & open TDMS files by MATLAB?

 

Thanks,

Sauvik Das Gupta

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

There's a way you can access TDMS files in MATLAB:

http://zone.ni.com/devzone/cda/tut/p/id/7446

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