LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to count sqaure wave analog pulses in daq6341

Hi,

I want to know whether we can count square wave pulses in daq 6341. Please help me with any procedure. I dont have any external hardware components to count the pulses. I tried several counter circuits and when run them they automatically without any input control and when I connect the counter to the square wave simulated signal, I am unable to connect them. please provide me a solution for this....

0 Kudos
Message 1 of 5
(1,860 Views)

Hi Dinesh,

 

the USB6341 supports 4 counter inputs, so you can "count square wave pulses"!

 

The "procedure" is explained in the manual for the USB6341 and in all those DAQmx example VIs regarding counter tasks…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 5
(1,828 Views)

In the past I have had a request to show the actual analog waveform, as well as process data about it.  In those cases you can try to take samples in the AI instead of the counter input, and then post process them.  Here is an example where a single PWM pulse drop out was being detected.

 

https://forums.ni.com/t5/LabVIEW/Detect-PWM-Drop-Out/td-p/2610921

 

Which worked okay but was later improved with a two level threshold code made by CrossRulz.

 

https://forums.ni.com/t5/LabVIEW/Two-Threshold-Analog-to-Digital/m-p/2738970#M809660

 

These might help if you end up going with the AI route.

0 Kudos
Message 3 of 5
(1,822 Views)

Sir, We are doing a project to detect the speed of a machine using daq. But here we had a problem that we can only use software part to do this project and cannot use the hardware as now we are not allowed to lab. So, please provide me a solution without any counter inputs. Can we use the simulate signal component to generate a square wave signal and refer it as speed pulses and give it to counter?? will the counter count those pulses ??please provide me any program file, it will be very helpful....

 

thank you sir

0 Kudos
Message 4 of 5
(1,776 Views)

Well, you can't use a DAQ counter if you don't have access to DAQ hw, right?

 

So sure, you can simulate a pulse train signal (see the palette Signal Generation->Square Wave).  But you're going to need to post-process that data in your software. 

   I'd display it on a graph for reference, and then put together the simple algorithm for detecting and counting relevant edges.

 

 

-Kevin P

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Summary of my reasons in this post, part of a voluminous thread of mostly complaints starting here).
0 Kudos
Message 5 of 5
(1,766 Views)