Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

using C#, AnalogWaveform , .GetRawData() vs .Samples

Solved!
Go to solution

Hi -  simple question:

 

suppose i have some acquired data in the form AnalogWaveform<double>[] , 

and i want to write it to disk (without wasting time, as i'm working on real-time continuous acquisition)

 

what is the difference between AnalogWaveform.Samples   and AnalogWaveform.GetRawData()   ?  what are the advantages/disadvantages? 

 

thanks!

0 Kudos
Message 1 of 3
(4,720 Views)
Solution
Accepted by topic author chicago_joe

Chicago_Joe,

The raw data is the data before scaling has been applied, whereas the samples will already have been converted to actual voltages.  Thus, for datalogging purposes, it is probably more useful to save the samples.  However, it is possible to manually convert the raw data to voltages.  Here is an example program (in LabVIEW and C++, but the same thing could be done in C#) that takes raw data and converts it.  Also, if you want to know more about the raw data, here is a KnowledgeBase article that talks about it.  It specifically refers to DAQmx functions in LabVIEW, but the same thing applies when using DAQmx with C#. 

 

-Christina

Message 2 of 3
(4,700 Views)
thanks very much!
0 Kudos
Message 3 of 3
(4,694 Views)