On Sun, Sep 6, 2009 at 12:10 AM, Terry Harris wrote: > The code in the document counts all edges. There are 4 edges for a 'pulse' > on one channel. Are you sure you are not misunderstanding the datasheet > (and actually have a problem when you only get 3 counts?). AHA! I think you have hit the nail on the head Terry. The encoders I'm currently using have a tiny bit of wobble so it's possible that occasionally they're missing a step and that's how I get 3 counts. For the most part it's pretty rock solid at 4 counts, and if I turn the encoder slowly and carefully I can get it to do single steps (mostly - sometimes there's a bit of jitter). So...is there a standard way to deal with this? If I want one click to be one event, should I just do a counter or is there more elegant code that I'm just not thinking of? Thanks! Josh -- A common mistake that people make when trying to design something completely foolproof is to underestimate the ingenuity of complete fools. -Douglas Adams -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist