Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Data acquisition with NI 6225, .NET C# ReadMultiSample in a Loop -> ERROR

Hi, We are trying to acquire data from analog input channel in a loop. We are using ReadMultiSample function. But when we increase the loop count then system hangs. ... analogInTask.AIChannels.CreateVoltageChannel("/Dev1/ai0", "ICh1", AITerminalConfiguration.Rse, -10, 10, AIVoltageUnits.Volts); AnalogSingleChannelReader reader = new AnalogSingleChannelReader(analogInTask.Stream); analogInTask.Timing.ConfigureSampleClock("", frequency, SampleClockActiveEdge.Falling, SampleQuantityMode.FiniteSamples, samples); ... for (int i = 0; i < loopCount; ++i) { lock (lockIt) { stopwatch.Start(); results = reader.ReadMultiSample(samples); stopwatch.Stop(); } ... We want to prepare statistics of elapsed time. Is it allowed to do such an operation? If no then how we can do that in .net? We are using .NET 4.5.2. -Arati
0 Kudos
Message 1 of 1
(2,557 Views)