09-28-2015 06:11 AM
Hello all,
I have an optical encoder that generates a digital pulse for every 1 revolution of a motor. I am trying to construct a VI that will count these digital pulses and deliver an output pulse on the Nth count - where N is a user specified number of counts. I have seen a few similar examples of this online but am still unable to find exactly what I am looking for. Can anyone help with this? I am using a NI USB- 6009 DAQ device.
Thanks.
Solved! Go to Solution.
09-28-2015 06:21 AM
Hi ciaran,
what pulse frequencies we are talking about?
The USB6009 has a counter, which is able to count (up) your pulses. You only need to check the current count with your limit to output a pulse on one of the DigOut pins.
When the frequency is rather low (<=50Hz) you can even use one of the DigIn pins to check for your pulse "manually"!
09-28-2015 06:26 AM
Hello Gerd,
Thanks for your reply. My pulses vary depending on the angular velocity of the motor. The max RPM is approximately 6000, which corresponds to 100Hz. This would be the max pulse frequency that I would be counting.
Ciaran
09-28-2015 07:05 AM
09-29-2015 03:35 AM
Hi Gerd,
Yes I'm using the counter pin on the USB6009. I can read and display the count number and generate an output pulse at a certain count number. What I need to do, and am struggling with, is generate a sequence of pulses at every Nth count.
09-29-2015 03:55 AM
Hi ciaran,
generate a sequence of pulses at every Nth count
Where do you struggle?
You can already output a single pulse on a digital output. What's the problem to output a series of pulses?
Remeber: the USB6009 is a very low-cost device, offering very limited possibilities. You can only use software timing when generating pulses, so there is no difference in generating a single pulse or a pulse train!