Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

Synchronizing Counter Reading with Digital output pulse

Solved!
Go to solution
Highlighted

Hey all,

I am developing a VI in which I have to synchronize the reading of the counter with the Digital output pulse which is used for other purpose (I need to know the value of the counter after each falling edge of the Digital output pulse). My DAQ device is USB-6351, if anyone is familiar with how to get started with this situation, ANY help would be greatly appreciated. I am very new to LabView and I am currently spending all of my free time reading through manuals and help files. 

 

Please let me know if you need any sort of additional information from me to understand what I am doing.

 

0 Kudos
Message 1 of 3
(1,097 Views)
Highlighted
Solution
Accepted by topic author Dileep2628

1. Start from a shipping example.  Go to the menu "Help-->Find Examples...".   Then select "Hardware Input and Output-->DAQmx-->Counter Input."   Then pick either the Finite or Continuous flavor of "Counter -- Count Edges".  (Actually, you may as well try both and learn from their differences.)

 

2. The 'Input Terminal' is the signal whose edges will increment your counter's count value.

 

3. The 'Sample Clock Source' is the signal whose edge will sample and buffer the instantaneous count value.  This should be the digital output pulse you refer to.

 

4. On the block diagram, go to the call to DAQmx Timing.  There's an unwired input called 'active edge'.  Right-click it and create a control.  Double click the control to find it on your front panel and place it around the other "Timing Settings".  Set it for falling edge polarity.

 

5. Run it!

 

Note: the 6351 is part of the very nice X-series family of multifunction boards.  They're really versatile, you can do a lot with them.

 

 

-Kevin P

Message 2 of 3
(985 Views)
Highlighted

Thank you so much for the solution Kevin it worked 🙂

 

0 Kudos
Message 3 of 3
(621 Views)