Total build cost:
Optical sensor (OPB3849A): $5
Resistors: $0.50
----------------------------------------
$5.50
See video for circuit and how to install.
The part number of the Optical sensor I used is OPB3849A, this is one type of many that will work. The biggest difference with the sensors is the package size and the gap of the IR slot.
NOTE: If you do this mod, you musy use my image of retropie. Otherwise you risk damaging your Pi.
Why not 3D print this button insert for a coin slot?
You can add some features or extra functionality by sacrificing a button with these custom inserts. I printed these on my PrintrBot Simple Metal (which I would reccomend btw).
The first insert will house a switch. The second is a slot for US quaters. The under side of this insert has a flat area to mount a optical sensor to build a working coin acceptor. I will add more photos of this assembly when I get more optical sensors in the mail :)
I included the STL and AutoCAD Inventor 2014 files.
The switch an opening of 0.505" x 0.805" (+/- 0.01"). The quarter insert has an opening of 0.90" x 0.095". Quarter slot is slightly oversized to accound for tolerance issues due to PLA shrinkage and different printers. I am slightly new to 3D printing; accounting for shrinkage and printer accuracy is all over the place for me.
The STL files are in milimeters (mm).
Inserts fit 1.125" button holes.