Welcome, Guest
Username Password: Remember me
  • Page:
  • 1

TOPIC: How to create a high speed counter:

How to create a high speed counter: 6 years, 8 months ago #13

Port A and B can be configures as either quadrature encoder
input or step and direction input. When used as Step and Direction, you can use port A as a high speed counter
Simply issue "MS0" (stands for Mode-Step-Zero).

This will clear out the external encoder counter register
(CTR) and set it to zero.hen for each incoming pulse on port A, CTR will increment (or decrement) it's value depending on the logic level of port B.

You can also set Port B as an output and control the
direction of count.his method can be sued to reliably count at rates up to 2megahertz.
  • Page:
  • 1
Moderators: hsummer, csearcy
Time to create page: 0.77 seconds