ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

obtaining encoder counts after 2ms

I need to obtain the velocity of the wheels which is attached to a rotary encoder. Currently i am using the DAQ6024e card.

i set my encoder to initial count of 1000000 and i want to read the counts after every 2ms.

I know how to obtain the counts from the encoder but how do i read the counts after every 2ms?

can someone advise me on how to program to read the encoder counts after every 2 ms?

By taking the difference in the counts every 2ms, i will be able to obtain the velocity by dividing the counts by 2ms.

can someone kindly advise?

regards,

Leroy
0 Kudos
Message 1 of 2
(2,560 Views)
the only accurate way i know of doing this is to use a counter to time your acquisition. however there are only 2 counters on the 6024e. you should only be using one of them. so you should be able to use one counter to trigger acquisition every 2ms.
0 Kudos
Message 2 of 2
(2,560 Views)