Quote:
Originally Posted by Abwehr
You can use an ultrasonic ranging sensor, like the one recommended above, or an infrared proximity sensor (I recommend the Sharp GP line, available from a number of retailers if you google "sharp infrared sensor").
The easiest solution is to put one sensor looking to the left, one sensor looking to the right, and one looking dead ahead. Alternatively, put one sensor looking forward and to the left, and the other forward and to the right (both on 45 degree angles). You could also put a single sensor on a servo and scan back and forth, but this is a bit more complicated.
Now all you have to do is write code to turn right when an obstacle is to the left, turn left when an obstacle is to the right.
If there's an obstacle in front of you, you can turn either way, or reverse (up to you!).
You can make this as simple or as advanced as you want. It could be as easy as what I described, or as hard as making a closed-loop control function to always keep you a certain distance away from the wall.
|
Yes, I would highly recommend the Sharp IR proximity sensors. I have found them to be much more reliable than the Maxbotix ultrasonics (though they would probably work just fine too.) Then I would write a program (assuming you are using three sensors as outlined above) to keep your robot centered in the hall using the two side sensors. (You can also check yourself, because I'm assuming the halls are about the same width, uniformly. By reading in your two sensors, you can easily determine if there are alternate ways to go other than straight.)
Next, I would use some GTS (the KOP ONE was great.... remember the second one is broken out of the box, and requires surface-mount soldering to fix (which our AWESOME mentor Mr. Allsop was able to do !!)) to keep track of your approximate distance. That way, if you had a course of attack, you could say "go forward approximately 28.3 feet, and at that point, start looking for turns". This way it's more difficult for the bot to get caught up somewhere it doesn't know where it is.
Quote:
Originally Posted by Dad1279
If the walls and floor are different colors, you might want to try a prior year's camera. However I think the software would be more complex.
|
CMUcam2 could work WONDERS in this application. With just 5 or 6 easyC code blocks, you could get your camera driving your bot around using color tags. If you had the ability to post colored sheets of paper in the halls to give the bot signals to turn, that would be awesome! If not, you could EASILY find identifiable colors to use as triggers for your bot.
Just let us know what you want to do, and we'd be happy to help you out. You can always PM me for assistance, or even call! I'd be happy to help!!!
Jacob