If the robot collides with an object, a bumper is pushed backwards, and the touchsensor is activated. As soon as the object is not touched anymore, the bumper falls back into its original position, and the touchsensor is deactivated again. As with the motors, modified LEGO cables are used to connect the touchsensors to the Handy Board. Infrared Reflectance Optosensors Two QRB1114 infrared reflectance optosensors from Quality Technologies are used to distinguish between black and white surfaces. They are mounted on the front of the robot facing down, about a centimeter above the ground.
Infrared light is emitted, reflected by the ground, and received by the sensor.
The infrared reflectance sensors are also connected to the Handy Board with self-made cables. It is not recommended, however, to use these values at that resolution. Because of small differences in the sensors, and disturbing lights in the environment of the robot, fewer different colours can be measured reliably. To increase the reliability of the optosensors, a calibration routine should be run each time the robot is used. In this scenario, the user puts the robot on a particular surface, and lets it read its optosensor values.