Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

What is the relationship with sample rate and number of samples per channel?

Solved!
Go to solution

In my world, if I wanted to sample for 10s at 10Hz (100S/ch), I would specify a rate of 10 and a sample count of 100.  This operation would take 10s to return data.  The task does not seem to behave this way.  No matter what rate and number of samples I choose, I get spammed with data at 1 Hz or faster.

 

What am I doing wrong?

Programming Data Acquisition and Control in Measurement Studio and Labwindows/CVI
0 Kudos
Message 1 of 4
(4,445 Views)

Hey Michael,

 

What kind of hardware are you using and would you mind posting an example of your code so that I may better assist you?

 

 

Regards,

Isaac S. 

Regards,
Isaac S.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 4
(4,430 Views)

NI 9239 on a USB carrier or a PCI board.  I have tried this in the aquire continuous voltage sample program as well.

 

                For a = 0 To HSChannelCount - 1
                    With HSChannels(a)
                        TriggeredAITask.AIChannels.CreateVoltageChannel(.Device & "/" & .Channel, "", AITerminalConfiguration.Differential, _
                                                                     .Min, .Max, AIVoltageUnits.Volts)
                    End With
                Next

                TriggeredAITask.Timing.ConfigureSampleClock("", HSSampleRate, _
                    SampleClockActiveEdge.Rising, SampleQuantityMode.ContinuousSamples, HSSampleCount)

               TriggeredAITask.Control(TaskAction.Verify)

                TriggeredAIReader = New AnalogMultiChannelReader(TriggeredAITask.Stream)

                TriggeredAIReader.SynchronizeCallbacks = True
                TriggeredAIReader.BeginReadMultiSample(HSSampleCount, TriggeredCallback, TriggeredAITask)

 

Programming Data Acquisition and Control in Measurement Studio and Labwindows/CVI
0 Kudos
Message 3 of 4
(4,427 Views)
Solution
Accepted by topic author DieselPower

This problem was solved by doing a phone support request.  It turns out that the minimum sample rate of the NI 9239 is 14xx S/s.  I am not sure why there is a minimum sample rate, but now I must move on to the next issue discussed at this link:

 

http://forums.ni.com/t5/Multifunction-DAQ/How-can-I-read-gt-10X-samples-at-a-sample-rate-of-X/td-p/2...

Programming Data Acquisition and Control in Measurement Studio and Labwindows/CVI
0 Kudos
Message 4 of 4
(4,403 Views)