ASAR object tracking bot
Overview:
This is ASAR a robot built with an intention of using a raspberry pi as its brain. Unfortunately the raspberry pi is not available until the end of May 2012, so I am having to tether it to my laptop whilst I develop the software for its behaviour.
Physical components:
Physically the robot consists of a webcam mounted on a pan and tilt bracket with two servos and it is using a H Bridge IC to drive the motors in a hacked Big Trak Jr chasis (cheapest way to get two DC motors in a chasis ready to go!). Im not so hot on the electronics, but I managed to cobble this together with some help from an expert friend!
Platform:
First I used OpenCV with haar face detection (see the video). Currently I am working on opencv HSV thresholding to make the bot to follow a tennis green ball and nudge the ball once it is close enough. This is working in its most basic form, the next steps is to develop a more sophisticated algorithm for the robot to hunt for the ball based upon the balls last known exit point from its field of vision. This however is proving more difficult than anticipated.
Future work:
Traditional object detection
Update:
Have got a Raspberry Pi on backorder, downside not going to arrive till end of April May!
Have updated the code and got basic body ajustment based upon servo pan position. Its adjustment accuracy depends on how close the ball is, but its a start.
Also started coding a search function, for when the ball is not found when the ball is not detected, but hit problems of the camera freezing whilst running the pan servo through 20-170 degrees.
Have been investigating reading values from the Aurdino, found Python firmata, https://github.com/lupeke/python-firmata/tree/98260401b92ce82399f8e795c87cb70cfd71d171, I hope to use this to combine another source of object detection, yet to be decided on. This will ensure the bot doesnt crash into anything whilsts its searching for the ball.
Update 25/3/2012
The Aurdino delivery has now been put back until the end of May due to the much publicised non magnetic jack issue. I have done no further development on the robot code base, as I am working 7000 miles away from home. I thought about taking the robot with me, but I was worried about customs confiscating it.
Video archive
Backwards forwards http://www.youtube.com/watch?v=g0jcZnh-fMw
Haar face detection http://www.youtube.com/watch?v=oSC3BwQiu1w
OpenCV, HSV thresholding for object detection, bot moves towards target, adjusts position when it gets close enough
- Actuators / output devices: DC Motors, Servos, piezo speaker
- Control method: semi-controlled/auto
- CPU: Aurdino
- Operating system: Linux on the PC
- Power source: 5V USB, 3 x AA rechargable batteries
- Programming language: Python w OpenCV, Aurdino sketchbook
- Sensors / input devices: Webcam
- Target environment: indoor on smooth surfaces