Rotary Decoder timing question

Hi Folks,

I've built a PC interface that utilizes the parallel port and polls switches via addressing multiple16 input multiplex chips (4097s). To maximize lines I used SIPOs to select both chip (0-7) and input (0-15). However my polling loop maxes out at about 30-40ms because of this bottleneck and often polls more slowly as the software acts immediately on this info and can bog things if there are a lot of events assigned to switches (average 60ms).

I have tried using quadrature rotaries with this interface using a decoder based on the PIC16F676. They work okay but it appears I'm missing a lot of the output (monitoring a digital display that should increment/decrement in response to the rotary). The designer advised me that they were programmed for use with a 10ms polling loop in a microcontroller circuit but that with a few modifications they could be "tuned" to a 60ms polling loop.

I haven't had a chance to program the chips with his new firmware but will be trying soon. However could someone verify that one can in fact "tune" the output of a decoder to accomodate a slower polling speed and that I might see better performance e.g. less "misses" and smoother increment/decrement? I'm thinking of designing my own decoder around an

8051 but wondering if it is reasonable to expect I can use quadrature rotaries with an interface that polls at 60ms intervals. I know the 8051 can handle the decoding but can I get meaningful info into the PC at its 60ms rate on the other side of the decoder? How slow can I go ?

Thanks!

Scott

Reply to
petdoc
Loading thread data ...

I find around 2.5ms is about right for a mechanical rotary encoder with 18 detents (and bounce). 60ms sounds WAY too slow. Depends on how many detents etc and how big the knob is and how fast it is rotated, of course.

If the microcontroller is keeping track of the +/-counts internally it can pass along multiple counts over a bottleneck and still not miss any. I believe PC mouse controllers do something along those lines.

Best regards, Spehro Pefhany

--
"it's the network..."                          "The Journey is the reward"
speff@interlog.com             Info for manufacturers: http://www.trexon.com
 Click to see the full signature
Reply to
Spehro Pefhany

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.