Using Motor Encoder with Arduino?

rwgast:
Ive obviously got the wrong idea about something here.. This is how im thinking about Encoders

In order to keep track of pulses you need to count them obviously so for every hi pulse you would increment a variable. You would need to monitor two channels for each encoder, so overall to read a quad encoder you need two pins and two variables. This is just a simplification of things, ignoring overflow.

Two pins and one variable. You only need interrupt handler on only one of the pins (in CHANGE mode) if you're
prepared to reduce precision by a factor of two. On the pin change XOR the two pins together - result is direction.

digitalRead() is quite slow, so direct port manipulation can really speed up such interrupt processing.