0% found this document useful (0 votes)
72 views

Obstacle Avoidance/Maze Solver: Brian Rojas and Khushpreet Buttar December 11, 2015

This report describes the process of building and programming a robot with two functions: obstacle avoidance and maze solving. The robot was built using an Arduino Uno microcontroller, ultrasonic sensor, motor shield and chassis kit. Version 1 of the software enables obstacle avoidance using the ultrasonic sensor to measure distances. Version 2 adds maze solving functionality using a left wall following algorithm. The project helped the authors learn that real world performance may differ from theory due to unaccounted variables, highlighting areas for potential hardware and software improvements.

Uploaded by

Sanjay Sangwan
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
72 views

Obstacle Avoidance/Maze Solver: Brian Rojas and Khushpreet Buttar December 11, 2015

This report describes the process of building and programming a robot with two functions: obstacle avoidance and maze solving. The robot was built using an Arduino Uno microcontroller, ultrasonic sensor, motor shield and chassis kit. Version 1 of the software enables obstacle avoidance using the ultrasonic sensor to measure distances. Version 2 adds maze solving functionality using a left wall following algorithm. The project helped the authors learn that real world performance may differ from theory due to unaccounted variables, highlighting areas for potential hardware and software improvements.

Uploaded by

Sanjay Sangwan
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

OBSTACLE AVOIDANCE/MAZE SOLVER

Brian Rojas and Khushpreet Buttar


December 11, 2015

Merced College – Fall 2015


CPSC 42- 1737
Summary
This report shows the process behind a robot that has two functions. One of the functions it has is
to avoid obstacles and the other function is to solve mazes. To build this we bought a kit for the
chassis, to hold the necessary components. The brain of the robot is a microcontroller called
Arduino Uno, which powers the motor shield and the servo for the head. This project helped us
understand that what works in theory might not work in real life application, therefore you have
to take into account as many variables as you can that might have an effect on the project.
Table of Contents
1.0 Introduction ............................................................................................................................................ 3
2.0 Building the Robot .................................................................................................................................. 3
3.0 Building the Circuit .................................................................................................................................. 4
4.0 Finished Product ..................................................................................................................................... 5
5.0 The Software ........................................................................................................................................... 6
5.1 Version 1: Obstacle Avoidance ........................................................................................................... 6
Main Loop ............................................................................................................................................. 6
Functions ............................................................................................................................................... 6
5.2 Version 2: Maze Solver ....................................................................................................................... 7
Main Loop ............................................................................................................................................. 7
Functions ............................................................................................................................................... 7
6.0 Conclusion ............................................................................................................................................. 10
7.0 References ............................................................................................................................................ 11
1.0 Introduction
Version 1 of The Robot’s task is to avoid any obstacle in its way. Using the ultrasonic sensor to
calculate the distance it can successfully move without crashing. Version 2 of The Robot is to
calculate its surroundings and find the exit path of a maze using the left hand solution, where you
can solve a maze by always turning left when you can.

2.0 Building the Robot


Building the robot was not too difficult, because of the kit that was bought. Assembling the head
that would hold the servo was difficult, because we wanted it to be easily replaceable in case the
servo would fail. There were only two parts we had to buy, the motor shield and the chassis kit.
Rest of the parts we already had from previous projects. The parts we used included a SG90
Servo, Ultrasonic Sensor, L293D Motor Shield, and Makerfair robot car chassis kit.
Parts:

Servo Ultrasonic Sensor Motor Shield

Chassis Kit
3.0 Building the Circuit
Once all the parts are accounted for, it was time to start building the circuit. A small breadboard
was used as the circuit board. This way it was easier to switch out any broken wires, due to the
head spinning.
4.0 Finished Product
5.0 The Software
This project was basically two different projects, version 1 and version 2. Once version 1 was
completed, we had time to think about what else can be done with the robot without making any
major changes to the hardware, so we decided to program version 2 to solve mazes using the left
hand rule.

5.1 Version 1: Obstacle Avoidance


Main Loop

Functions
5.2 Version 2: Maze Solver
Main Loop

Functions
6.0 Conclusion
It was a fun and educating project to finish. There were some problems that we had a really hard
time with but, we managed to fix it with programming and hardware adjustments. A few things
that would have made this project easier would be to use three ultrasonic sensors instead of one.
This way we can always check the robots surroundings and make smoother movements. Another
thing we could have done is use servos as wheels instead of dc motors, which would make more
accurate turns. There are a lot of things that can still be improved in both hardware and code.
Sometimes you have to keep in mind that if your project is going to be used as a real world
application, make sure you account for any variables that might affect its overall performance.
7.0 References
McCabe, Patrick. Instructables . n.d. http://www.instructables.com/id/Maze-Solving-Robot/. 10 11 2015.

You might also like