Time Measurement and Position Encoders, photo-interrupters and other motion sensors generate a pulse in response to a known incremental move in position. The position of an object can be continually measured by connecting the output of an encoder (or other sensor) to a counter that increments or decrements every time the sensor generates a pulse. The value of the counter indicates the position of the object quantized to the resolution of the sensor. That is, if a sensor generates 10 pulses per revolution, the resolution of the position measurement can be no better than 1/10th of a revolution. Standard encoder/counter cards measure the position of an object by capturing the value of the position counter at user specified times. Because counter cards only provide counter values as a means of measuring position, the position measured using counter cards will always be quantized to +/- 1/2 count. In contrast to the measurement of position strictly using counters, the Motion Capture card measures the time of pulse transitions from encoders to more accurately measure the position of an object. These time/position value pairs represent the actual position of the encoder at the measured time because it is at these transition times that the position counter increments/decrements. As illustrated below, the actual time/position values can be used to interpolate to sample times to more accurately convey the motion measured by the encoder. Of course the Motion Capture card also supports the direct measurement of the position counters without time measurement to accommodate applications that only need strobed position measurements. Time Measurement and Velocity Computations The computation of velocity requires that you know two position values and the time at which an object was at these two positions. Velocity can be approximated using a counter card by reading a computer's clock every time the counter card is read. Although valid for approximating velocity, you are precluded from accurately measuring velocity because there is always an uncertainty in time between the event of reading the computer's clock and the event of reading the counter card. Using precisely timed interrupts greatly enhances your ability to measure velocity, but the counter card approach still stuffers because the resolution of the velocity measurement drops as the velocity of an object decreases to zero. This can be illustrated by a quick example. Assume a position sensor on a rotating object generates a pulse every 15mS and you are sampling the counter card every 10mS. Sometimes you'll read two different position values (velocity > 0) and sometimes you'll read two identical position values (velocity = 0). Your measured velocity will subsequently hunt between 0.0 and some finite value. Because the motion capture hardware from Euclid Research gives you time measurement values with your position measurements, you can accurately compute velocities down to zero. |