I'm working on a micromouse, a small autonomous robot that traverses a maze.
I need an efficient way to measure lateral distance to walls and I'm looking at the
Sharp GP2D120
but looking at the datasheet, it has long typical response time of 39ms, is quite bulky, and has a minimum distance of 4cm.
Can you recommend a better sensor (that possibly has a lower minimum distance)?
I was wondering what are some alternate ways of measuring distance? I have seen other micromice use IR LEDs and it was interesting but I'm not sure how it works.
Any input is appreciated. Thanks!
Best Answer
I have read somewhere (I think the Arduino forums) that sharp no longer manufactures these sensors (though that can be hearsay). I do know however that they are quite expensive compared to much simpler solutions.
The simplest would be a IR LED - IR phototransistor combination:
Phototransistor on left, led on right
You would power the IR LED (remeber the limiting resistor!) and then use the phototransistor to pick it up. The voltage drop over the phototransistor will be proportional to the intensity of the IR light it picks up which is proportional to the distance the emitter and detector are from the reflecting surface.
Pointers (Personal Experience):
There are many links on the internet on how to use said components. Take a look here: http://letsmakerobots.com/node/2907
Lastly, this method (I have found) is only accurate over small distances (not more than 20cm I'd say). For longer ranges you should consider ultrasonics or those fancy Sharp sensors.