So, I'm working on an interesting problem. It's somewhat self-assigned, but it'll make it's way into some customer equipment. It's not quite DSP, not quite circuits, but I'm posting it to these groups anyway.
The application is an optical encoder -- shine light through a disk at some photosensors, look at the result, and tell the processor where the disk is. There are some tried-and-true methods, but I want to do better.
I want to be able to use an encoder to rapidly -- but not immediately -- figure out the absolute position of a wheel. Sort of a hybrid absolute/ relative encoder, that's not as expensive as using N strips to get the
2^N precision of an absolute encoder, but that gets you an absolute position quicker than the "go around until you see an index pulse" that you get from a pure relative encoder.My thought is to use a quadrature encoder in the usual way to figure out the relative motion of the wheel, and then back that up by a strip that is encoded in binary (dark = 0, light = 1) with some scheme such that any consecutive string of N positions is unique.
And I figured out one such scheme! Take the output of an N-bit LFSR, and lay it down in order. If the idea of having 2^N - 1 bits bothers you, then augment the LFSR such that it has one string of N zeros on its output, giving you a nice even 2^N positions.
Then, to figure out the absolute position of the wheel, use the quadrature encoder to to run by N bits in either direction. Use the looked-up bits to determine the position (which you can, because they're unique), and voila! You have the absolute position and can now just use the relative encoder.
So my question is: has anyone seen this done? Are there better variations? Is there anyone who makes some sort of off-the-shelf solution that does all that, but cheaper than I could ever roll my own from individual components? My ideal would be a sensor that I could buy off the shelf, and specify to my customer how their code disk would have to be made, and have everything just work.
(Note that if you had the freedom to roll your own silicon you could make a system that would register a code word, look it up for the absolute position, then figure out its offset within the sensor. This would give you oodles of precision and an immediate answer -- but it'd be ridiculously expensive to roll one from scratch).
Thanks in advance.