DAQExpress

cancel
Showing results for 
Search instead for 
Did you mean: 

Changing Counter Input Sample Frequency

Hi All,

New here so I hope this isn't an elementary level question. I have a USB-6210 and am recording data from 3 different analog inputs. I am using a digital edge trigger to start the data collection and am able to set the sampling rate to 100hz. I wanted the software to count the rising edges for me so I added a task at the top for Counter Input. I find it annoying that I have to go into both tasks and hit record to be able to simultaneously log data for both the analog voltage readings and the edge counts. I am sure there is a way to use LabView VI but I am unfamiliar with the programming aspect. Onto the problem. When I look at the data that has been logged, the analog voltage is recording a data point every .01 seconds and the counter is recording a data point every .1 seconds. When I pull them into excel the numbers don't line up. 

 

Does anyone know how to change the sampling rate for the counter input? Or somehow get them synced up together using the VI?

 

Thanks in advance!

-Nick

0 Kudos
Message 1 of 4
(3,845 Views)

Hey Nick,
I think that the "Counter - Count Edges (Continuous Clock).vi" LabVIEW example will help you achieve what you need. The following is a screenshot of part of the block diagram of this example:
image.png

You can see that the sample rate is defined by the DAQmx Timing VI. Give it a try and let us know if it worked for ya. 

0 Kudos
Message 2 of 4
(3,829 Views)

I don't see that as an example in DAQExpress. Is that in different software? 

 

See attached screenshot of the only examples I see...

 

Is there a different place you can find examples for LabVIEW VI?

0 Kudos
Message 3 of 4
(3,802 Views)

Hi Nick,

 

I'm not sure if you already figured this out, but essentially you'll want to go from using your individual tasks to acquire data to actually calling your tasks in a .gvi in DAQExpress. Attached is the 'Acquire and Log' analog input example that I've modified.

 

The tasks just allow a simple way to interact with your hardware, when you actually want to have multiple tasks or some automation involved you'll want to program in a .gvi.

 

 

Andrew B.
Application Engineer
National Instruments.
http://www.ni.com/support
Download All
0 Kudos
Message 4 of 4
(3,786 Views)