Autonomous robot that returns to charging station when battery runs low
This Lego autonomous rover just drives around uselessly until the battery drops under a certain level. At that point it wil go look for the charging station. It does this by driving in one direction, using a digital compass. When it hits a wall, it'll turn 90 degrees right until it hits another wall. Then it tries to turn to the first direction again and eventually the rover will pass the charging station (as it is in the back of the room). When it does, it will receive an RC5 IR signal from the charging station and it it knows it is at the charging station. It stops and parks into the charging station.
The charging station (driven by an Arduino Duemilanove) notices the presence of the rover by an distance measurement. When the rover drives into the charging station, the charging station will start a pump that drives a few pneumatic cilinders that make contact with the contact points on the rover. The power of the charger is enabled and the clock will count down for 10 hours.
When 10 hours are passed, the charging station will disconnect the charger by retracting the pneumatic cilinders. At that point the rover notices the voltage drop and comes out of hibernation and starts the autonomous program and the cycle starts over again :)
The rover can also be controlled by an old TV philips remote...