Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

USB-621x: Connect a encoder output to a counter input

2 views
Skip to first unread message

LostInHelp

unread,
Jul 21, 2008, 11:40:11 AM7/21/08
to
Hello,
 
I'm using an USB-621x board. In my application I have two counters:
1. First one is used as an encoder (x4)
2. Second one is used as period counter.
What I want to do and I didn't manage until now is to connect the output of the encoder to the input of the counter. In other words I want to measure the period of each impulse that is generated by the encoder.
I've tried a lot of thinks untile now, but I didn't mange to find the right solution. All the time I was getting some errors that one terminal is not connected proper or the other one.
Please, if anybody can provide a small example I will be very happy. Only a small vi where the encoder output is connected to a counter that measure the period.
 
Thank a lot,
LostInHelp

Hillman

unread,
Aug 5, 2008, 12:40:10 PM8/5/08
to
Hi lostinhelp - nice name Here is an example for you. The source for the CI DAQmx function is cDAQ1Mod5/ctr0, where the CTR 0 GATE is connected to my A phase of my quadrature encoder. Then one turn, pause, and turn of the encoder gives a data value - the time between pulses - which is the pulse width. (for encoder). Hope this helps, post more if you still have questions,thanks<img src="file:///C:/DOCUME%7E1/ukhillmj/LOCALS%7E1/Temp/moz-screenshot.jpg" alt=""><img src="file:///C:/DOCUME%7E1/ukhillmj/LOCALS%7E1/Temp/moz-screenshot-1.jpg" alt="">


time between pulses.vi:
http://forums.ni.com/attachments/ni/40/6633/1/time between pulses.vi

0 new messages