i am mechatronics engineer , have got diploma in embedded systems using microcontroller ATmega16.
my graduation project was a tour guide robot , your project was a part of the robot as the robot has obstacles avoidance using ultraviolet sensor , the sensor send rays if it is bounced back the robot can measure the distance between and avoid the obstacle.
the idea is much the same except in your project using infrared sensor