r's web
About R2
Year: 2002
MCU: Atmel AT89C2051
Clock: 12MHz
Memory: 2kB on chip flash (program)
256B on chip RAM (data + stack)
external I2C EEPROM
Battery: 8x 1.2V NiCd AA cels
Sensors: 2x IR transistor (line detection)
3x bumper (obstracle detection)
2x wheel position sensor
Actuators: 2x standard hobby servo HS-422
Programming language: A51 Assembler
Description: Each servo was modified for continuous rotation. Potentiometers was replaced with incremental sensors from PS2 "ball" mouse. Actual position was updated in mouse chip and read back using PS2 protocol as X and Y coordinates of cursor. Three mouse buttons was used as front bumpers to detect obstracle and its position.
Line following algorithm was very simple and trying to keep line under two infra-red sensors. If line was missing under either of sensors, the opposite servo was slowed down. When no line was detected, searching algorith was used.
Obstracle avoidance was implemented as resursive algorith able to "go around" objects with more complex form. Three bumpers was used to identify obstracle position and decide driving direction.