My idea gives absolute position on start-up, but perhaps I did not explain sufficiently. Construct the slider a linear slider that can move though co-linear equally- spaced optical interruptors. The slider is longer than the distance between two of the interruptors, such that at any position it covers one or two of the interrupters. Its position is determined by the state of the interrupters. At one end of the slide, it is acceptable that the slide covers none of the interrupters, since that is a unique condition. Eg, consider 4 interrupters A, B, C, and D, then the slider can cover none, A, A&B, B, B&C, C, C&D, or D --- 8 positions. Generally, n interruptors will give 2n positions. Obviously this would work as well with optical reflector sensors, or contacts, such as microswitches. David Example of interrupter: http://www.fairchildsemi.com/ds/H2/H21LOI.pdf Example of reflective sensor: http://www.fairchildsemi.com/ds/QR/QRE1113.GR.pdf Quoting ivp : > > I don't think you commented on my suggestion to use optical > > interruptors. It would seem these combine simplicity and robustness. > > Apologies. I'm thinking though about position information and what > can happen when the power is off. That also rules out simple physical > contacts. For example, if each position produces just one pulse then > the s/w has no idea of the relative position. That takes information > and that probably means driving each LED with its own frequency, > and that will mean a greater component count and some extra cost > > If optos were to be used, I might make something like a circular PCB > with 5 LEDs shining through a binary pattern of holes into 5 receivers. > This would possibly become more attractive than a pot as the number > of discrete positions increased. It could even be arranged as a drum, > LEDs shining through holes rather like a tape reader > > wbr > -- > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist > -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist