Using a mouse chip to measure optical flow

For very small UAVs, especially those used indoors, an interesting way to navigate is using a technique called "optical flow". Basically, it's the way flies see: they detect motion rather than resolve images. As you move, the objects closest to you appear to move the fastest, which for a camera chip means pixels shifting position faster.

The video above is from a Swiss team that have used optical flow to steer indoor blimps and microlight aircraft (video here). They've got pretty fancy equipment and lots of money--but is there a way to do the same on the cheap?

Yes. It turns out that the sensor on an optical mouse (you probably have a few laying around) can do the job. Here are instructions on how to take the chip from an old mouse and connect it to a Basic Stamp (an Arduino would work even better) and create a low-budget optical flow sensor. Taking the dx, dy information from that and using it to drive the airplane's servos or actuators to move in the opposite direction from the highest optical flow should be a pretty easy matter. The only tricky thing is integrating the mouse chip and processor into a package no larger and heavier than the RC receiver that this optical autopilot replaces.

The schematic on the mouse chip to Basic Stamp circuit is below:

Views: 11187

Comment by Peter Klemperer on May 8, 2008 at 10:25pm
Very cool. Too bad my landlord looks down on painting the room to look like a zebra. :(
Comment by Howard Gordon on May 9, 2008 at 8:19am
Here's another DIY article on using a mouse sensor for optical flow -
http://home.roadrunner.com/~maccody/robotics/croms-1/croms-1.html
Comment by Jack Crossfire on May 9, 2008 at 10:28am
Now we just need to get people to swap their blimps for coaxial copters. It costs more but saves $1,000,000,000,000,000,000 in rent.
Comment by Alexander Grau on May 7, 2009 at 1:03pm
We did only simulate everthing (RC airplane, optical mouse sensor, and a simple flight controller) - and it shows that it's possible - even in 4 days :-) http://grauonline.de/wordpress/?p=28
Comment by Andrew Helgeson on May 14, 2009 at 8:26am
Keeping it real simple, use a slit with a couple of photo detectors, 1 slit/axis.
Its the way PIR motion sensors used to be made, before they went to the fancy fresnel lens.
I started experimenting with this technique on the bench, watching the trace on a CRO.
I then used the circuit from a mouse, I was trying to get head positioning for a VR headset.
I worked for relative motion, but getting absolute head tracking was hard.
Comment by ovidio aza on February 11, 2011 at 7:54am
no pude mirar el optical flow
Comment by ovidio aza on February 11, 2011 at 1:26pm
para que exactamente sirve el optical flow y como funciona
Comment by Clinton Mckinnon on November 25, 2012 at 4:55pm

Hi Chris

Could you please provide a modern link to the bs2 software etc

thanks Clinton

Comment

You need to be a member of DIY Drones to add comments!

Join DIY Drones

© 2017   Created by Chris Anderson.   Powered by

Badges  |  Report an Issue  |  Terms of Service