Light Sensing Car

This project was made for the 4-H robotics contest, and abided by their requirements. We chose to build a light sensing car, that spins until it finds a light source, and follows it indefinitely until the light is turned off. The 4-H contest requirements are as follows.
- You can use any elements in the Sparkfun kit. You can use resources in 1100 Learned to build your project. When working in 1100, be sure to wear safety glasses and complete the EHS training. Other sensors, motors, and materials can be used as needed. 3D printing is also possible if a team member knows how to do that. Making the project out of easy to access materials does make it a more accessible project for kids.
- The system should have some sort of actuation. This should be accomplished with one of the motors provided in the kit.
- You can use materials beyond the sparkfun kit. Be sure to include all materials in the necessary parts list.
- Once your group has completed the project, you should create an instructional document and video for the project. We will also print posters and have a demonstration.
- The projects will be assessed on:
- Originality
- Functionality
- Appearance and presentation of the project (including the poster and instructables page)
- Quality of instructional materials
Supplies


• Arduino Uno R3
• White Solderless Breadboard
• Photoresistors (2 total)
• Wires (2 sets)
• Button (x1)
• Spartkfun Motor Driver
• L293D Motor Controller
• Rubber Wheels (2 total)
• Hobby Gearmotors (2 total)
• Zip Ties
• Wago connectors
• Tape
• SolidWorks 3D printed shell
Assemble the Chassis

• 3D print the chassis using the provided SolidWorks model.
• Insert the hobby gearmotors into the designated motor slots.
• Mount the rubber wheels onto the motor shafts.
Circuit Setup

• Attach the Arduino Uno onto the breadboard.
• Wire the circuit based on the circuit diagram shown in the poster:
• Connect photoresistors to analog inputs (A0, A1).
• Connect motors through the L293D motor driver.
• Wire the motor driver to the Arduino’s digital output pins.
• Use Wago connectors or solder where necessary.
Secure Components


• Zip tie or tape the Arduino, breadboard, and battery securely to the chassis.
• Route wires carefully to avoid tangles or contact with moving parts.
• Ensure photoresistors are exposed and facing forward.
Upload the Code
• Write or upload the Arduino sketch that matches the flowchart logic:
• Initialize pins
• Continuously read light levels from photoresistors
• Compare left vs right input
• Drive forward or turn accordingly to follow the brightest light source
Downloads
Test the Car
• Place the car on the floor.
• Shine a flashlight in front of it—observe it follow the light.
• Confirm it avoids obstacles and adjusts direction as expected.