Introduction: Mouse Cam

Picture of Mouse Cam

Use an optical mouse for low resolution imaging. The picture is that of an "e" under the mouse.

Step 1: The Inspiration for the Project

Picture of The Inspiration for the Project

I was looking at this page: optical mouse cam and the comments of people who wanted to do it but was unsure how to proceed.

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

Picture of Remove the Controller Chip

When you get your mouse, open it. The optical sensor can be distinguished by it being just above the lens. It should have eight pins, and have a sort of sun logo on it, and also the inscription "A2610". In that case, it is the Agilent ADNS2610 optical mouse sensor, the same as used by spritemods, and (later) by me. If it has more than eight legs, or a different part number, these instructions might not work.

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

Picture of The Sensor

The picture shows a closeup of the sensor chip and I have labelled the pins according to the datasheet.

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

Picture of The Underside of the Board

The picture shows the underside of the board. The optical sensor has been protected with a bit of tape.

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

Picture of The Printer Connector

Over to the other side, you need a parallel (centronics) port, commonly called a printer port, on your computer. That is a 25 pin D connector, of which four lines are used.

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

Picture of Construction - Fit the Diode

You need a diode, for example the 1N4148. Solder it with the end with the band to pin 5 of the connector. That is, the cathode of the diode goes to pin 5.

Step 7: The Other End of the Diode

Picture of The Other End of the Diode

Now solder a wire (or use the lead of the diode itself) and connect the other end of the diode to pin 12. That is, the anode of the diode connects to pin 12.

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

Picture of Connect the Cable

I used a piece of flatcable from a hard drive cable to connect the mouse board to the printer connector. The numbers in the figure below refer to the pin numbers of the optical sensor chip.

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

Picture of Make It Work

Once it is connected up to the parallel port, the software has to be downloaded and run in order to see the output on the computer screen. The program is called "Readmouse" and is available here. It is a zip archive which has to be downloaded, unzipped, and then follow the instructions in the readme files.

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.


gdw (author)2008-02-09

Does this make use of the on board micro controller at all? In other words, would this work if you took the chip off of the board and put it in a bread board, for example?

neelandan (author)gdw2008-02-11

This does NOT make use of the on board micro controller. It will work if you take the sensor chip and supporting components off to a custom made board. I do not think it will work in a breadboard, because of the high frequency signals and decoupling needed around the sensor chip.

tyler roberts (author)neelandan2015-05-29

it should, and the signals in question are nowhere near fast enough to warrant a custom pcb, so a breadboard or even dead-bug would work.

computeras2 (author)2014-08-30

does it works with serial rs232

S33PlusPlus (author)2011-04-17

Just a heads up, but the text is far too fuzzy to read, even at full size.

rjunior-1 (author)2011-03-09

Do you can put the brand and model of mouse that were used? I opened five mouses and none of them has the ADNS2610. I would like to do the experiement with a mouse that was tested. Thanks a lot.

brew93 (author)2009-06-13

The link is broken.

neelandan (author)brew932009-06-13

I shall upload my copy.

karthvks (author)neelandan2010-09-18

can i get the copy
my e-id

sweaterlife (author)2010-06-18

Using the 3060 for a university project, but the link you posted to a 3060 project is broken(and I assume no longer hosted)...any chance you have a hard copy downloaded? I did this one and it worked great thanks (Y)!

nalinda4nr (author)2010-02-15

Link doesn't work. Can u upload it again.

Colonel88 (author)2009-09-09

SOme pics please?

Corpy (author)2008-10-29

I have 16 pin's sensor what i can do whit it?

Sinnedskull (author)2008-08-31

Wow this wonder full but can i ask favor? can i ask the source of the dll that you use? Pleas...

raysireks (author)2007-10-04

maybe a fingerprint scanner? have you tried to run your finger over it and see what shows?

altaria1993 (author)raysireks2008-07-27

yeah, that would be cool, though i think you would need a little more leds then, but thats easy to do ;)

altaria1993 (author)2008-07-27

yay, tomorrow, when the stores are open again, i'll buy a parallel port thingy, so i dont have to solder to my motherboard, and try to find a diode somewhere (i got some somewhere.. i jus't dont know where..)

nicko170 (author)2008-01-25

Such a nice Instructable. Thanks.
I have updated the program to include a Capture feature so that you can save images easier. Link Source is included.
This also worked for the A1610 chip. I used a standard Compaq Presario mouse.
- Nick

theadamlevy (author)2007-11-29

its a good thing you didnt use the mouse to take the pictures for this instructable :) clever im glad there are people out there that would figure this stuff out cus the extent of my time wasting goes to reading it

dan (author)2007-09-27

hmm, very nifty. i think the main features of these sensors are low resolution but very high frame rate, low res is not much help so we should think about what the super high frame rate could be useful for.

Kiteman (author)dan2007-09-27

Muzzle-velocity sensor?

jimbo112 (author)Kiteman2007-09-27

how would tyou be able to tell where the bullet was? it would just be a smudge in the immages, and

Kiteman (author)jimbo1122007-09-28

Maybe not for a normal gun, but for a spud-gun, or anything else with a relatively slow muzzle velocity - use a dark projectile against a light background & measure the distance travelled between frames.

Digital_Anarchy (author)Kiteman2007-10-05

get your mouse and slide it as fast as your can across your desk top. unless you have a super awesome gaming mouse it will probably screw up and the cursor will just move erracticly. the frame rate cant be that good

TechnoMancer (author)jimbo1122007-09-27

you put a differnet lens on the sensor and aim it very carefully!!!!!

royalestel (author)dan2007-09-29

Get an array of them together to make a higher resolution gestalt-cam.

Shinji (author)2007-10-03

very ingenious! bravo.

TechnoMancer (author)2007-09-27

BTW the url to the site where this comes from originally and where the software comes from is:

neelandan (author)TechnoMancer2007-09-29

Here is another web page, using the sixteen pin ADNS3060:

bleachworthy (author)2007-09-27

very nicely done! I'll bet if you scanned the rest of that, and printed it, you could easily sell that as abstract art. one question though, what is the purpose of the diode shorting those two particular pins?

wiml (author)bleachworthy2007-09-27

The SDIO signal on the mouse chip is bidirectional, it acts as an input or an output at different times. The printer pins are all one-directional, either inputs or outputs. The diode converts the printer port output pin's "1" signal into a "high-Z" signal (or rather, a lack of signal) so that you can use the other pin to read the signal sent by the chip. Normally you would use an open-collector output for talking to an I2C bus, this imitates that.

the diode does not short the pins *consults pinout for parallel port* the diode connects the data3 pin and the paper empty pin together i have no idea why this is done but it has probably got something to do with the interfacing between the computer and the chip.

the data3 pin is used as output and the paper empty for input the diode is (i think) a clamp diode to protect the computer from high voltage spikes.

Spectrace (author)2007-09-27

i have seen people do this and use it as a barcode scanner, as you can tell from your scan, that it similar to a barcode. Maybe it can be used as that, YAY.. good structable!

About This Instructable




Bio: I'm Chandra Sekhar, and I live in India. I am interested in electronics, and building small one-off circuits around tiny chips (the electronic kind).
More by neelandan:Gooseneck Light and MagnifierWireless L E D9V battery case for projects
Add instructable to: