Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

TDMS trigger

Hello,

 

What my application requires is Analog Input Data & Counter Data stored in a TDMS file.  Specifically, I need the ability for the DAQ to be on and reading/displaying all the time, but the user needs the ability to Start and Stop the TDMS logging using a button.  After the stop it will automatically get saved using user preferences.  I cannot find any examples or documentation on how to accomplish this.

 

 

Thanks,

0 Kudos
Message 1 of 2
(4,754 Views)

Hi Matt0316,

 

There are two common ways to collect data as TDMS in VB.NET. The first way is to configure the DAQmx task to log to the TDMS files and then you can manipulate the data after the fact or you can stream to the TDMS files programmatically. 

 

For the first option you can find an example of how to configure DAQmx to perform TDMS logging in the following location:

<Start> » All Programs » National Instruments » NI-DAQ » Text-Based Code Support » .NET 4.0 Examples

In the Examples folder navigate to: <Examples>/Analog In/Measure Voltage/TdmsContAcqVoltageSamples_IntClk

 

For the second option you can find an example of streaming to TDMS files in the following location:

<Start> » All Programs » National Instruments » Measurement Studio » .NET Examples

In the Examples folder navigate to: <Examples>/Tdms/Streaming/


Milan
0 Kudos
Message 2 of 2
(4,742 Views)