Hack an optical mouse into a camera with Arduino and Processing
HTML-код
- Опубликовано: 3 июн 2010
- Grab the frame buffer from an optical mouse with Arduino. Low blood sugar special, guest starring twin peaks theme and 1024x768 t-shirt. Code available at conorpeterson.wordpress.com/20...
View my other stuff:
conorpeterson.wordpress.com Наука
So now I understand how some 240p videos on RUclips are made.
hhhhhh good one
just picturing all those sex tapes were made with homeboy swinging a mouse around.
have you never hear of 144p ?
@@LEFTYSMOKER Ball mouse
there is some 144p too
If only every video could be filmed this well. It'a almost always in focus, pointing at relevant components, WITH audible audio. Nice work.
Even a soundtrack.
Most epic 4-cable-soldering EVER
The music sounded like you were having a romantic date with the mouse lol.
Jam Tart its from the Twin Peaks soundtrack :)
Hahahaha.... mouse love
@@glamdrag Mousa Palmer
This is best edited hardware hack documentation video i have ever seen. Great work on that. I especially liked the romantic soldering scene.
The hack itself is also pretty cool.
I wondering if it's sensitive to Color?
If yes can we use this sensor to make Arduino based optical Spectrum Analyser using Diffraction Grading.
Nice project.Please can You tell me what camera did use for recording?cheers
Could it be used as as a motion sensor...say to light an led when a hot wheel car crosses the finish line?
thank you for the Twin Peaks soundtrack. brings back memories :)
hey, thanks for posting this! love the twin peaks sound track too!
@iBlackwind Are you asking if it's possible to write a driver for the iPad that lets it pull data from an optical mouse camera? Good god, I have no idea. Doesn't the iPad already have a perfectly good camera (that actually focuses beyond 2mm?)
Can we use old mobile ccd or cmos camera sensor with arduino ??????
The dramatic slowmo at 3:00 absolutely destroyed me. 🤣🤣🤣
This has amazing applications! I have had to come back to this video to remind myself of the idea i had. Thanks for your video!
have a ? for you.I have afew wireless keyboards with no receivers could you inform me if i can use other transmitters or if i can make them into wired keyboards( just maybe the diagram of what each color represents on a usb cable) thats if i can actually be able to wire them. thanks
The music choice and the slow motion is hilarious!
80's love song while "mating" wires and components...
@Conor Peterson how about using it to measure laser reflection by amplifying with lenses? Is it quick enough for a lidar?
how you are getting the visual output onto your computer, i check your link you had mentioned but it had moved on, ..........so can you tell me what software you used to see display
Hey Conor great video. I like your method of wirestripping :O) I can't remember how many times I've done that myself.
That's a cool hack. I've been working on an embedded project that requires a colour digital camera, but upon trolling adafruit and sparkfun, there are currently no cheap camera modules (complete with frame grabbers) available for hobbyists - not that it's a hobby project, but the prototype for what I'm building has to start somewhere. I haven't considered looking into single chip colour cameras or image sensors. So, this really simplifies things :D.
@nws15
You may be able to write a driver for certain mice to dump the image, but I doubt it could be done with matlab. The optical data is buried pretty deeply in the mouse hardware.
Do anyone know where I can find this mouse ? Because some of the recent mices don't work the same I guess so I just wanna have like that one if anyone knows where I can find it ?
Not only very interesting stuff, very good music too!
Thank you!
Hi Mike, everything ok?
It would be cool of you did this with a modern mouse
Yes
Did you film this video using one of those ? 2010 lolz.
+Luc4s. :)
After watching your video, I had a flashback into the past when I watching RUclips videos was so beneficial.
How well do the detect heat??? For Infra red detection?
10 FPS is a hardware limit or a bottleneck caused by the Arduino/PC interface? I feel like my screen pointer tracks my hand movements much faster than at 10 Hz
I think this is because you read the memory of the chip, while normally the chip tells the microprocessor in the mouse the movements only... He is saying something like that, just before he explains the pins.
It Is because of the image processing right?
The Avago data sheet for that sensor chip says it operates at 1500 frames per second. It would operate at that rate in a mouse in which the sensor chip is translating images into motion. When you want to read the images off the chip you are constrained by the speed of the sensor chip's serial interface. Reading images that way is just for diagnostic purposes.
high .... I have a project that the Arduino sending vedio images ,, like 4 images per second ... and because the the camera sending stream data , I woulde love to know what's the Arduino that do the jop ...
Sir, Is it possible by connecting some two points in mouse circuit or ic or camera, thereby cursor will move left right up and down, I have to make Mouse emulator, if yes than I will control mouse over Arduino. Sir Plz guide.
So is it possible to write a driver for a camera module for the ipad?
what if you another glass wont that change the range a bit??
Pls would you help me by giving me an informatic project by arduino projects have relation to pc and the maintenance of pc
so this method works with every optical mouse with any sensor inside or is there a certain type to do the job?thanks.
You're pretty much right. One possible application I found was to use it for low-budget optical interferometry, that is, to detect minute vibrations or even temperature shifts by placing the sensor between interfering laser beams (or more like, a single laser beam interfering with itself). I had to pack up my things for an abrupt cross-country move before I could get it working reliably and never documented it, so if that's interesting to you, maybe it IS your turn.
Thanks Conor! I learned what i needed to know
Why when we stop moving mouse...the serial monitors show x=0 and y=0, it suppose have reading right ?
Hi. i m trying to use optical mouse with arduino for receiving mouse's motion(i know this is the normal function that every mouse does, except that m trying this with arduino). the prob is that my mouse uses some 14 pin IC, the datasheet of which i can't trace(may b it's chinese). So i want to use the D+ and D- of usb port of mouse for getting the change in location. can u provide me some link where arduino is used this way. or rather how can I (using 1 serial port of Uno) get the job done.
Immediately subbed for twin peaks theme.
Qual livro vc indica de hacker para hardware firmware?
have you tried the same with a newer PAN101?
Can you show us the circuit and the code please ?
Dear sir,
Thanks for sharing.
Barcode scanner from line camera is possible? For spectrometer...
Thanks for your answer.
Would you provide a link to the code? I'm not seeing it on the old or new site. Thanks for the video.
Conor, can you use this same concept for recycling old cellphone cameras?
@@jubmeca y de las grandes
could this be used to control the flow of filament extruded at the hot end of a 3D printer..
generally good. did get a really good understanding of how optical mouse works. no wonder it wont work on glass surfaces
I think this can work as an optical flow sensor for arduino for example, which helps in stabilizing an object (e.g. hovering copter). It may serve the purpose of a motion sensor as well.
gyro would work better + soo much suppoet will be there from fellow enthusiasts
use it as a cheap biometric reader for finger prints?
Still useful in 2020 Thanx!!
hi
wat if i dun have arduino?
can i use USB cable to connect mouse to computer instead of connecting to arduino by using matlab programming?
Please add captions (English and universal translation) Seems like a good video but I cannot hear. You moved your website, but did not update your links
hi can you hack a mouse chip by adding a potentiometer to it for changing mouse cursor position ? i mean like when u turn porentiometer to left the cursor of pc will go left
Fatih Saruhan use old mouse which contain rotary encoder
Are you going to update the description to fix the link?
Nice. Love the Twin Peaks homage.
There's a USB serial driver that's part of the arduino software. Aside from that, all source code can be found at the link in the description. It's in java (for Processing) and straight C (for Arduino).
This is hilarious that you used that music. Well done.
Could we turn this into a arduino line follower? or the like
That was very impressive and pretty cool thumbs up from me, might have a play with your code if its still out there! Thank you for this, it is incredably informative if you are into this stuff and if you are not!
Than would I be able to get a cheap webcam and turn it into a high quality mouse if i reverse this process?
I thought something surreal was about to happen when the Twin Peaks soldering montage got going. I think it added something to the general quirky vibe of the editing and presentation.
hi i was thinking of a DIY project with the optical mouse. i was planning to use the camera of the optical mouse to take images of a finger placed on top of it and correlating the resulting spectral information to measure say, heartbeat or even blood sugar concentration through digital image processing. i think this is possible since the infrared light can penetrate the tissue thereby images captured can be used to determine the analyte of interest
Seems a perfect candidate for experiments with machine vision. Even sewing machines use this technology for speed control. Could be applied to woodcarving, automobile detailing, package printing, even robots.
the tracking firmware in that mouse when refocused to infinity can give direct axis steering outputs to make a drone lock on and home in on a target...without an arduino. its a fun project to try. surprised more uses for these sensors are not posted.
how did you make soldering into a movie moment?
"I'm done with this"
Great video
can this be used as a line tracking sensor for a robot
Yes
@iRouRoui in the video I used a vise from home depot, but a popular tool used for this purpose is known as a "third hand" and is available at most hobbyist websites (sparkfun, jameco, etc.)
It's a really gd vid.but the thing that i wanna know,u used a software to see the surface image snapped by the sensor.what's the name of that software?Thanks in advance :)
Awesome, I have some old mice i'd like to recycle and this could become a cool project to tinker with, thanks a lot
JUST LIKE A PATIENT IN EMERGENCY ROOM WHILE SOLDERING THE WIRE LOL,,,KEEP UP THE GOOD WORK
Hey Guy Could You Do that, a camera of phone use like mouse air? please answer my question.
Cant understand after soldring what he ha done plz give me answer??
Great stuff.Where can get more references about this?
I can think of a good use for this, a weatherproof switch/direction control for a robot or outdoor interface in an RF intense environment. Of course finger skin doesn't work well with red so the LED would need to be changed. Impressive! What did you use to bring up the image? I'm a PIC head, so... Oh and if you want better music for you video (yank) I can score your stuff for free/fun/advice lol
@HazakyProductions Theme from twin peaks.
Great Hack!
Like the honest comments....and using my own preferred method of skinning wire insulation!!!
Keep up the good work.
I think we could use it for some apparatus that does some scanning work. May be someone needs to make some small scale production line and check if products has been made correctly.
How about using a lens from a disposable camera and using the mouse as a barcode scanner?
tell me the name of the song please
interesting video and concept, my first impression is how could I use this in my CNC, optical sensor, something to remember
Can you use this to make an optical counter that can count say, rpm of a spinning object? I have placed a white thumb tack on a black edged 3/4" spinning disk and would like determine how fast it is spinning. I could have the disk spin a laser light crossing the lens each revolution. Any ideas how to create an optical counter?
Open an old mouse for that there is a infrared sensor and a spinning wheel wich you can use for this counting
is it possible to do the same but with a nokia 5610 camera?
Conor, cool vid. What kind of vice is that you're using? Where did you get it?
It's a Portable Vacuum Base 360 Degree Swivel Vise from my local big box home improvement store.
where i can find the code? for arduino
if you could detect how much to the left or right someting moves you could use it to control a motor and find a specific position. that could be really useful
dude, u nailed it bro👌👌
Love the twin peaks sound track :D
i think you can use that as a linear encoder that can move on both the x-y axis
Thanks, it was good one, I'm going to make, but I'll enhance lenses to get fine focus.
Good idea.
Shiii ... whats the music playin while soldering? I remember this song from when i was a little kid. I need the name of that! :
what white wire is that? Conor Peterson
the twin peaks song made this awesome!
what course did you get in college?
Awesome hack... Music made me cry!
FIre Walk With Me is a great instrumental. Kinda funny you started soldering when it started playing, it reminded me of the opening to Twin Peaks where the machine is sharpening the saw blade! Great timing. Too bad that camera cant be used for distance.
Great video, the music choice was hilarious.
You'd never get a job editing build montages for the A-Team :-)
In fact there's a remix idea!
Why are you stuck with the little plastic lens, which focuses at about 1mm (the distance of the surface it normally tracks)? Surely you could use some other lens, for example from a camera, that will focus an image onto the surface of the chip? It would be very interesting to see what it makes of an actual picture.
Fun Hack! I always thought the mouse imager might be handy for a surface-visible auto-hover for tiny aircraft and little helicopters. On further investigation, turns out it's very true. I can remember having this thought the first time I saw a SUN Micro Sparc optical mouse, but at the time wasn't game to waste one to prove the point.
Also insert any other "deflect-the-controls-in-proportion-to-the-image-changing" application here.
Great work... i want to try this....