Let's Make Robots!

Autonomous robot that returns to charging station when battery runs low

Drive around until battery runs low, then it will look for the charging station to get some juice



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...


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Could you please provide more details on how the beacon functions, which parts were used and how you track direction? I really like your project :-)

The charging station emits always a 38kHz IR beacon. 
Schematic: http://www.robotroom.com/Infrared555.html

The charging station is positioned in a smart place in my living room: the transistion from the living room into the kitchen which is just 1 meter wide. The rover has two modes: drive around avoiding obstacles and looking for the charging station. If the rover passes the charging station while driving around, it picks up the 38kHz signal which generates an interrupt. The rover cannot pass this point to make sure that the rover remains always on one side of the charging station. It will always pick up the signal, since the "corridor" is just 1 meter wide.

When the battery runs low, the rover will go and look for the charging station. It'll do that by turning into a certain direction using a digital compass. After turning it'll drive until it hits the wall. If it hits the wall, it knows that it has to go right where the charging station is. In the meantime it keeps looking to the left, making it a wall follower. It could be that the rover has encountered furniture and hasn't reached the wall yet. So when it detects it can go to the left some more, it will do that and it will turn to the right again to follow it's path. Soon or later it will pass the small "corridor" between the living room and kitchen and thus the charging station.

It then picks up the 38kHz signal, it turns to a certain direction using the compass and then drives back until it is in the charging station.

Clear? :)

Nice work!!

I like that station ;)

I love your video, its a movie, good background music, the characters are Great Actors !!!   LOL


Most seriously, I am building a robot with the battery charging station feature, like you.

My batteries will be a LiPo, need 20 minutes to charge.


My question :

How you interact between the Arduino and the Battery charger ?


A distance sensor is connected to the Arduino of the charging station. This sensor polls if the rover is present or not. If not, it does nothing but sending an IR signal in RC5 codation. Once the rover drives into the station, the distance sensor gives a high value and the charging station knows that it can start the charging procedure.

The pneumatic cilinders are driven by a certain amount of time and after that the charger is activated by a 12V relay that switches the 230V of the charger on. I just a standard charger for lead acid batteries.The average time that my battery of the rover needs to be fully charged is around 10 hours so after 10 hours the Arduino just simply switches the relay again, switching off the charger. So there's not really a "communication" between the arduino and the charger. I've solved it like this since it's the most easy way. If I wanted it to do more perfectly, I'd screw open the charger and use the signal of the charge LED to tell the Arduino that the battery is charged. But it's not necassary since the charger switches itself off once the battery is fully loaded.

Are you going to build your own charger or are you going to use a third party charger? Charging LiPo's is much more complicated than lead acid batteries...

Very good thinking to use the charger LED !

Shoot, sometime I need to think more !!!

If you don't want to open that charger you could put an LDR onto it at the outside watching the led to turn off.

I have always wanted to create a bot,that will return to charge it's battery automatically. Bravo!!

Man,it looks so cool..!!! That station seems to be from twenty-second century... good work and demonstration.

I loved the dramatisation of this. You have done a fantastic job with the lego. You really are an AlmightyArjen.
; D

Plus space themed LEGO are my favourite :D Reminds me of my "epic" battles good vs evil... but now with more awesome, and automation :D

The docking routine was surpringly quick (regarding my own expectations) :)

And good riddance evil space pirates! :P