I've design this rack and pinion latch to make some chest/box door latch that work with Arduino... It's for fun with the kids.
There are some bases to mount the parts over thick double corrugated cardboard : the cardboard is to be sandwiched between the base and parts.
Since it's 3D printed, fitting tolerance might not be good with your printer, so you might have to change some diameters or clearances after a test print...
Have fun and post what you've done with it.
Update 2020-05-23 : support et spurgear added for step motor
Since my 9g servo was a total crap (I don't have a brand, but the unit in the picture came from an Arduino Elegoo starter kit), I have modified my design to use a step motor that I had in hand (from the same kit). So I've change the support and the spurgear to accomaodate that step motor. I have also include a small push button holder on the support left end to ba able to zero the step motor...
bolt_rack.stl | 138.5KB | |
rack_servo_support.stl | 898.7KB | |
rack_STEPPER_support.stl | 2.1MB | |
spurgear.stl | 1.8MB | |
STEPPER_spurgear.stl | 1.8MB | |
strike.stl | 305.6KB | |
strike_base.stl | 131.1KB | |
support_base.stl | 154.6KB |