From: Dave H. <dhy...@gm...> - 2005-07-16 03:38:22
|
Hi Brendan, > Appendix A of what document? > What is the URL? Had some emails crossing. Here's the URL just in case: This web page: http://www.barello.net/Papers/Motion_Control/index.htm Scroll down to the section "Appendix A: Quadrature Decoding State Machine" has some code for doing quadrature decoding. > Looking at an absolute maximum frequency of 100KHz for each shaft > encoder (2 of them). > Realistically a maximum of about 33KHz for each one, but if I had newer > encoders with 512 counts/rev instead of the 180 counts/rev that I have, > then this could blow out to around 100KHz. The psuedo quadrature decoding only uses one interrupt line per channel and it's only about 20 instructions long. That means, in theory that you could run it about 800kHz (and consuming 100% of the CPU). So running 2 channels at 100 kHz should definitely be within the realms of possibility. --=20 Dave Hylands Vancouver, BC, Canada http://www.DaveHylands.com/ |