Quadrature Encoder for F281X

Target Category: F281X

Sub-Target Category: Quadrature Encoder

Description: The Quadrature Encoder block lets you read quadrature encoded counts. The Quadrature Encoder block requires two pins to work.

The Quadrature Encoder block has three outputs. The topmost output is a 16-bit integer representing the number of encoder counts. It cycles back to 0 when it reaches 65,535. The second output is the direction, which is +1 for forward and –1 for backward. The third output counts the index pulses when the corresponding parameter in the Quadrature Encoder dialog is activated.

Refer to the following table for information on encoder logic:

 

F2812

F2812

Encoder Channel A

QEP1

QEP3

Encoder Channel B

QEP2

QEP4

Encoder Index

CAP3

CAP5

Inc/Dec Rev Count on Index Pulse: Enables the counting of index pulses.

Quadrature Pins: Specifies the pins from which to read quadrature encoded counts. This parameter is available only for devices that support it.

Peripheral Interrupt: Specifies the interrupt for which you want to look.