> Gray code encoders, if cheap enough, usually are rotary (I never saw one = linear > at least). Pretty expensive anyway. Gray code encoder can be optical or use other sensors Gray code can be a SINGLE track with multiple sensors spaced along it in such a way that they between them "see" a gray code. Mathematicians used to say it was impossible. Nowadays its done. I don't know how hard it is to get 6 or 7 bits. BUT if you can use and end of track detector then you need simply two detectors in quadrature on a single track. Very standard. cf eg mechanical wheeled mouse. Each axis ha one "track" and two sensors. 36mm / 6 bits is about 0.5 mm/bit. Somewhat fine. An optical "window" with width affected by position would probably be easy enough. read light level shining through "window" to get position. Russell > --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .