Picture of Arduino Light Following Robot


This instructable will use three photoresistors (light dependent resistors) and an Arduino to control the motion of a robot. Any common robot chassis can be used for the robot. The light sensors will be mounted on the left side, right side and front of the robot. When light of sufficient intensity falls on a sensor, the robot will respond with a left turn, right turn or forward movement, corresponding to the location of the sensor that is activated. The instructable will also pass along some electronics tips that I have found useful and, hopefully, will prove useful to others.

Remove these adsRemove these ads by Signing Up

Step 1: List of Materials

Picture of List of Materials

List of Materials:

3x Light Dependent Resistors

3x 250K trimmers (potentiometers)

3x Three pin sensor cables

1x Duemilanove or compatible Arduino board

1x DFRobot motor shield shield&product_id=69#.UzInGthOWM8

1x Arduino proto shield

1x Robot Chassis

2x 4”x6” Proto boards

Various standoffs and hardware. A good kit can be found at

The standoffs used in this instructable are from a Trossen Robotics robot kit. The standoffs and hardware are also sold individually

1x 6AA battery holder

1x 9V battery holder with barrel plug

Finally, we will need some male and female headers

Step 2: Robot Platform

Picture of Robot Platform

Robot platform preparation. As mentioned, any common chassis can be used for the robot, and I chose the Arexx robot chassis listed above. This chassis had a rather small upper deck, thus the need for one of the proto boards. Put four 3cm (or similar) standoffs on the existing holes on the lower deck of the chassis, and then position the proto board on top of the standoffs to form the upper deck. Mark and drill screw holes. See accompanying photo. This gives us a platform that we can drill screw holes into to hold various electronics and sensors. This platform can be reused with other sensors in future robot projects.

JohnW5121 days ago

You listed a 9V batt holder in the parts list, but no mention of it was made in the assembly instructions. May we assume it was used to power the Arduino board? Of course the Arduino could also be powered by the 6xAA battery pack, but the electrical noise generated by brush-type DC motors would probably not make the microcontroller too happy. Is that why you used the 9V batt? Or did you use it after all. I don't see it in the finished robot.

SergioC25 months ago

on what software would i download the code?

can you the main circuit diagram.

how is the motor controlled?

I'm kind of new to the whole the robot thing

joesinstructables (author)  ThatArduino1 year ago

The motors are controlled by a DFRobot motor shield. Here's a youtube video describing the shield and here is a link to the manual

septimia71 year ago


BIGDOG19711 year ago

Great job. Very nice.

Take a look at my instructables too (my BUGBot)


And i been made analog car. :))

Nicely documented....Sweet Robot!!!!

A neat and nice project. Keep it up!