Step 1: The Inspiration for the Project
When I was gifted a failed optical mouse I opened it up and found that it had the same sensor as in the web page above. So I could repeat his work, and use the software he had developed.
The picture shows the board inside the mouse without modification.
Step 2: Remove the Controller Chip
Here, I have removed the controller chip and connected two links so that the signals from the sensor pass straight through.
The three pushbutton switches were removed to be used in some other project. The aluminium electrolytic capacitors were replaced with tantalum capacitors of the same values, but smaller.
Step 3: The Sensor
The writing on my mouse sensor says "A2610 C0517C" the first being the part number, and the second maybe the date and mfg code.
We have to connect to the Vdd, Gnd, sck and sdio pins (click on the image to view it full size).
Step 4: The Underside of the Board
I have labelled the two signal lines. The gnd area is the largest copper area on the board. The Vdd can be recognized by there being an electrolytic capacitor directly across it and gnd.
Step 5: The Printer Connector
On the figure, I have marked the four lines which are used. If you look closely, you will see that the pins are labelled with numbers.
Step 6: Construction - Fit the Diode
Step 7: The Other End of the Diode
Now check it. Pin 12 is at the very end but one, and there are six free pins between it and pin 5, where the other end of the diode is fixed.
Step 8: Connect the Cable
It is best to identify those wires using a multimeter, or some sort of continuity tester which will not damage the sensor chip.
Pin 3 of the sensor is the data in/out pin. It goes to the connector pin 12 directly, and to pin 5 via the diode.
Pin 4 of the sensor is the clock input. It goes directly to pin 9 of the connector.
Pin 6 of the sensor is ground. It connects to the large area of copper on the board, and to pin 25 of the connector.
Pin 7 of the sensor is the supply pin. It has to be supplied with +5 volts for the sensor to work. In the figure, this is the yellow wire, running back to a hard drive connector. If you have the original cable of the mouse, whether USB or PS/2, the five volt line will be present at the end. Just identify that and connect to it.
Step 9: Make It Work
The sourcecode of the program is included in that archive. The datasheet of the sensor is available here in case you get a different sensor and wish to modify the program to work with that.
The figure shows the output of my mouse camera when used as a scanner on a page containing some printed matter.
I think I shall continue to use my regular scanner, after all.