I see, so there is. If I can find them used, might be a good solution!
This may be very 1950's, and a little on the Rube Goldberg end of the scale, but what if some dial string (very rigid) was tied to the cam, wrapped a few times around the axle of a 10 turn linear potentiometer, and then secured with a tension spring? There would need to be some friction on the potentiometer axle of course, maybe heat shrink tubing.
A potentiometer shaft
B thread
C tension spring