Limit Switches
While searching the digikey website for photo detectors for another purpose, I came across some optical sensors that should work very well as limit switches. They reflect infrared light off a diffusing surface with a range of 2 to 22 mm. I assume the optimum distance is about 11 mm. Right now I plan on positioning them so they reflect off the bottom surface of the bearing block. They are small and flat and should fit nicely under the bearing block. I ordered two sensors (425-2042-ND), three connectors (one spare) (A98801-ND), and ten feet of ribbon cable (AE09G-10-ND) for about $13 plus shipping. The sensors use three wires: GND, 5V, and signal. I plan on pulling off three wire strips of ribbon cable and coloring one edge black (GND) and the other edge red (5V) with permanent markers. I can separate the wires at each end and keep a nice clean cable in between. My original thought was to buy the individual components and design my own circuit, but it would have cost more than buying the prebuilt sensor.