DAQExpress

cancel
Showing results for 
Search instead for 
Did you mean: 

Counter Input of USB-6212 slows down While-Loop

Hi All,

I want to program a while-loop in DAQExpress 3.3 in a LabView-VI which reads an analog and counter Input. The analog Input runs with a sample rate of 25 kHz. With the read-block of the Counter input in the loop, I only get about 1,000 loop-iterations per second shown in the panel while running through the program. Without the Counter input I get the desired 25,000 iterations per second. If I use SimDev1 /ctr0 as the counter instead of the USB-6212 counter, I also reach the 25,000 iterations per second. Is the sample rate limited by the hardware or is there a possibility to run the loop with both inputs at 25,000 iterations per second?

 

Used Hardware: USB-6212

Used software: DAQExpress Version 3.3

 

The .gvi and task-settings can be found in the attached screenshot.

 

Thanks in advance!

- Matthias

0 Kudos
Message 1 of 3
(3,121 Views)

Hey Matthias,


if you want to synchronise different types of inputs and outputs,

you have to invest some work into getting familiar with the DAQmx Api.

 

How you can solve the problem in LabVIEW and LabVIEW NXG can be foun in this whitepaper:

http://www.ni.com/example/30953/en/

 

Because DAQexpress does not offer the DAQmx Timing VI and DAQmx Trigger VI,

you have to work with the Task Property Node to make the settings.

 

I tested it with an USB-6218,
you can find the code as attachment.


Best regards
Matthias

Message 2 of 3
(3,034 Views)

Hi All,
I think this links can help you!
Synchronous Analog, Digital, and Encoder Measurements in LabVIEW
https://www.mccdaq.com/blog/2018/01/11/how-to-synchronous-analog-digital-and-encoder-measurements-in...

Synchronize Encoder Counter Input and Analog Input with DAQmx
https://forums.ni.com/t5/Example-Programs/Synchronize-Encoder-Counter-Input-and-Analog-Input-with-DA...




bhovhann
0 Kudos
Message 3 of 3
(3,014 Views)