Quantcast
Channel: Counter/Timer topics
Viewing all articles
Browse latest Browse all 1271

DAQmx Capture encoder value on digital input.

$
0
0

I am using a PXI-6221 DAQ card and LabVIEW 2012.

I have linear encoder that gives a quadrature signal and I have four proximity sensors that give a digital output.

I have successfully implemented example code that runs a while-loop and updates a display of the encoder position and digital inputs at regular interals.

I would like to capture the exact encoder value when each of the four digital inputs changes state. The simplest method might be to have the loop compare the previous state of the digital inputs via a shift-register and save the encoder value if there is a change. I would prefer to use hardware-triggering to get a more acurate measurement. Is there any example code that does something like this?


Viewing all articles
Browse latest Browse all 1271

Trending Articles