Como Hacer Un Micromouse
Post on 30-Oct-2015
Embed Size (px)
7/15/2019 Como Hacer Un Micromouse
AbstractThe IEEE micromouse competition has been apopular event among engineering students and engineers. A
micromouse is an autonomous vehicle whose objective is tofind the center of a 16 by 16 cell maze within 10 minutes.After exploring the maze for some time, the micromouse willattempt to make its fastest run from the starting point to thedestination cells. This report summarizes the design and
implementation of the MightyMouse project for the spring andfall semesters of 2005. The design method of theMightyMouse project consisted of two stages. The first stage
was to design and construct individual components. Thesecond stage of the design process was to interface thecomponents to form the final prototype. The individualcomponents of micromouse system consist of the motorcontrol system, navigation sensor array, digital compass fordetecting orientation, and a mapping system for navigating the
maze intelligently. A test plan was developed in order tovalidate the overall performance of the micromouse. A lifeproduct life cycle and reliability reports have also been writtenin hopes to encourage and aid future micromouse teams.
Index Termsmicromouse, autonomous, maze, IEEE
HE micromouse is an autonomous vehicle whose goal is
to find the center of a maze. The official IEEE
Micromouse Competitions began in 1987 at the World
Micromouse Competition, where David Otten of MIT
captured first and second place with his MITEE Mouse. This
competition used a new scoring system design to reward
intelligence, efficiency, and self reliance. Micromouse
competitions have become a popular event among engineering
students and engineers.
II. PROJECT DESCRIPTION
A. Problem StatementDesign and construction of a micromouse requires a broad
range of engineering skills. This combined with an open
design process makes the micromouse project a very practical
Manuscript received December 12, 2005. This senior design project was
sponsored by Dr. Herb Hess of the Electrical Engineering Department,
University of Idaho.
and challenging senior design project.
1) Objectives: The primary objective of this project is to
build an autonomous vehicle, a micromouse, according to
IEEE specifications which is able to navigate to the center of a
maze. A secondary objective is to design a full size maze also
in accordance to IEEE specifications.
2) Constraints: Constraints for the micromouse come fromregulatory competition rules. The mouse size, time allowedto solve the maze, methods for solving the maze, and amonetary limit placed on the final prototype are all constraints
imposed by IEEE competition rules.a) Size: The mouse is can be no larger than 25cm
square.b) Time Limit to solve maze: During a IEEE
competition the micromouse has 10 minutes to solve
the maze and complete the run.c) Battery life: The batteries must supply power to the
micromouse for at least 10 minutes.d) Micromouse expenses: The total cost for Micromouse
must not exceed $500.e) Maze: The maze consists of 16 x 16 cells; each cell is
18 cm square. The southwest corner is the startingcell. The four center cells are the destination.
B. Solution Method1) Brief Description: There are two fundamental phases to
our design process. The first phase was to design individual
components of the micromouse and get them to operate
according to individual specifications independent of one
another. The second phase was to interface the individual
components and have the micromouse operate as one
autonomous unit. The first semester of the Senior Design
course was dedicated to working on the individual
components. The goal of the second semester was to integrate
the individual components. The individual working
components include the navigation sensor array, mappingalgorithm, distance and bearing devices, motor control, and
An effective micromouse design must perform the
following functions in order to find the center of a maze
a) Recognize walls and openingsb) Stay centered within each cellc) Know position and bearing within the mazed) Control the distance needed to travele) Make precise 45 and 90 turns
MightyMouse: An Autonomous Maze SolvingRobot
Kelly Ridge, Sanjeev Giri, Peter Shaw, Jason Flynn
7/15/2019 Como Hacer Un Micromouse
f) Perform mechanicallyg) Navigate the maze intelligently
2) Overview of Micromouse functions: The mouse mustrecognize walls and openings in order to navigate the mazeand prevent crashes. The navigation sensor array provides the
mouse with this information. The navigation sensor arrayconsists of a combination of four short-range and two long-
range infrared sensors.The mouse must stay centered within the maze to prevent
compounding errors in distance and position calculations. Adigital compass determines if the deviates from its desiredbearing. This information is sent to the motor control systemto make proper corrections, either speeding up or slowingdown one wheel.
The motor control portion of the project is responsible forsafely moving the micromouse through the maze. There aretwo maximum speeds, one for the mapping portion of thecompetition and one for the racing portion of the competition.
The motor control code is given a distance to travel as input.It is then the responsibility of the motor control to accelerate
and decelerate the mouse during travel. The rate ofacceleration is fixed based upon the traction of the wheels onthe maze surface.
In order to ensure that the mouse is not slipping, the motorsare controlled with PI feedback. The shaft encoders (built intothe motors) read in the speed of the wheels and send this datato the motor control code that adjusts the speed of each wheel
accordingly.The mouse must keep track of position and bearing during
each run to provide navigation information to the mappingsystem. The shaft encoders that are built in to the motorsmonitor the distance the micromouse travels. The electronic
compass determines which direction the micromouse is facing.
The combination of these two systems provides the dataneeded by the mapping and navigation systems.To move efficiently through the maze the micromouse must
be able to make precise 90 turns. The digital compass ispolled during turns to provide control feedback to the motorsand navigation systems.
The mechanical soundness of the micromouse design is animportant factor. The chassis needs to keep the systems stable
during operation so accurate data is recorded. The chassisalso keeps the drive train in line in order to reduce the numberof path corrections made.
To successfully and efficiently solve the maze the mouse
must make intelligent navigation decisions based on its
current position. The mapping system utilizes a modifiedflood-fill algorithm to determine the best solution as the mazeis discovered.
C. Component Descriptions1) Sharp GP2D Sensor Array: The short-range sensor array
consisting of two Sharp GP2D120 infrared sensors is
interfaced to the microcontroller and can determine whenthere is an opening to the left or the right of the mouse.
These sensors are positioned so that the angle of incidencewith a sidewall is 90 degrees. The side sensors crossfire
across the body of the mouse thus keeping the sensors outside
the minimum firing range of 4cm. The side sensors aremounted directly to main circuit board of the mouse.
The long-range sensor array, consisting of two SharpGP2D12 infrared sensors, determines walls in front of or
behind the mouse and outputs their approximate distances.The long-range sensors cross-fired across the length of themicromouse preventing the sensors from exceeding the
minimum sensing range of 10cm.
Fig.1 Navigation Sensor Array
2) Devantech Digital Compass: The Devantech electroniccompass is interfaced to the microcontroller via an I2Cinterface. It returns values between 0 and 255 indicating itsrotational orientation. A one-time calibration is performed
that improves accuracy when the compass is moved to newlatitude.
The compass experiences strong electromagneticinterference when it is in close proximity to the DC motors.
The minimum distance required to yield accurate readings isapproximately three inches. The compass is also most
accurate when it is positioned horizontal to the ground. Theseconstraints forced the compass to be mounted on a pole wellabove the rest of the micromouse.
3) Mapping System: The mapping system solves a full
16x16 maze using input from the sensor array, shaft encoders,
and digital compass. The modified flood filled algorithm used
to solve the maze is explained in detail in the method of
solution section for the Mapping System.
4) Motor Drive System: The motor drive system consists oftwo DC motors with built in shaft encoders that are poweredby two monolithic H-bridge ICs. The ICs contains all of the
free-wheel diodes and power transistors necessary for drivingthe motors. Also, the input to the ICs is CMOS and TTL
compatible. These properties allow us to minimize the size ofthe circuitry necessary to power the mouse.
The Zilog project for controlling the H-bridge also
incorporates the shaft encoders, I2C compass, and the serialHyperTerminal output. This integration was done to helpensure that the code for controlling the motors will notinterfere with these other functions.
The built in shaft encoders are 16 count and output a square
wave. These magnetic encoders rely on hall-effect sensorsand are used for indication and control of both, shaft velocity
7/15/2019 Como Hacer Un Micromouse
and direction of rotation as well as for positioning. The
encoders provide the feedback for the motor drive system.
6) Chassis: The final prototype chassis was made out ofcarbon fiber. This allowed the chassis to be strong and rigidbut also lightweight. The chassis has a skid-plate design withmotor mounts incorporated into the carbon fiber.
7) Maze: The final maze design involved creating a mazethat was transportable as well as one that would last, thus
providing a solid testing and competition platform for futuremicromouse projects. The maze base consists of 4-5x5 ft
interlocking pieces of inch ACX plywood. The walls werecut into 18cm long by 3cm high strips from 12mm thickplywood. The walls come in four different configurations:perimeter, double-post, single-post, and no-post. The wallsides were painted white and the tops red. The base was
painted flat black. Paint colors are specified by IEEEmicromouse competition rules.
D. Method of Solution
1) Sharp GP2D Sensor Array: The Sharp GP2D InfraredSensors consist of an LED emitter and receiver and can be
used to determine the distance to an object based on the angleof reflected light. The sensors are insensitive to ambient lightand are reliable in detecting the reflected LED beam on anumber of different surfaces varying in both color and sheen.The sensors have an analog voltage output that corresponds to
the measured distance. These analog outputs are sampled bythe onboard Analog to Digital Converters of the Zilogmicrocontroller, providing a digital value that can be used forrange calculations. Drawbacks of the GP2D sensors are that
the relationship between the actual ranges and the A/Dconverted values is nonlinear and there are also slightdifferences in the outputs between sensors.
The Sharp GP2D120 short-range sensors had to benormalized in order to ensure accurate and repeatable readings
from all four sensors. To normalize the short-range sensors,20 readings were taken at each centimeter within themanufacturer specified range (4-30 cm) and then the readingsfrom each sensor at each range were averaged. A plot of these
A/D readings vs. the range produces a nonlinear curve (dataand graph available in Appendix C). This means that a largechange in the A/D value did not necessarily correspond to a
large change in range. For the micromouse to make decisions
based on sensor input there must be a direct correlationbetween the A/D value and the actual range. To find thiscorrelation a linear regression was performed on the averagedshort-range sensor data producing an equation relating the
A/D value to actual range.The function of the short-range sensors is to determine side
openings. The short-range sensors are continuously sampled
by the A/D converter to determine side openings. Taking intoaccount that the side sensors crossfire across the body of the
mouse: to still be able to determine an opening, the mousewould have to read a range value greater than approximately18 cm (corresponding to an A/D value of 323).
The function of the long-range sensors is to determine the
mouses proximity to front and rear walls. This information isuseful in mapping the maze as well as providing the motorcontrol algorithm with information on deceleration to avoidfront and rear crashes.
Regression data from the manufacturers website was used
for the purposes of testing the Sharp GP2D12 long-rangesensors. Data was taken to find linearization equations for
each long-range sensor in order to increase the absoluteaccuracy of their readings.
The navigation sensors act as the eyes of the mouse. Theyprovide the mouse with topographical information of themaze. The mapping algorithm relies on the sensors todetermine openings and walls in order to map the maze andmake decisions on the best path to the center. The long-range
sensors also provide the motor control algorithm withinformation on front and rear walls in order to avoid crashes.
2) Devantech Digital Compass: The electronic compasshelps the micromouse keep its bearings while navigating the
maze. Our micromouse design will use the compass moduleto make accurate 45 and 90 degree turns as well as to ensure
that the micromouse travels in a straight lineThe compass uses two Philips KMZ51 magnetic fieldsensors to detect the earths magnetic field. The sensors are
sampled by a PIC microcontroller and supporting circuitrywhich compute the compass direction and provides aninterface to the host Zilog system. The compass modulerequires a 5V supply at a nominal 15mA and provides data via
two output methods, I2C and a PWM signal.
Fig.3 Devantech Digital Compass Pin Out
7/15/2019 Como Hacer Un Micromouse
Pin 9 must be connected to the ground bus of the host
Pin 1 must be connected to a 5V supply
Pin 7is an input to select either a 50Hz (low) or a 60Hz(high) operating environment. This is used to reduce outputjitter caused by the mains power supply frequency. The
compass module has an onboard pull-up resistor and pin 7 canbe left floating for a 60Hz (U.S.) operating environment.
Pin 4 is the PWM output, which is not used in ourimplementation. It has in onboard pull-up resistor and can be
Pin 6enables a calibration mode, which is also available viathe I2C bus. It has in onboard pull-up resistor and can be leftfloating.
Pin 2 & 3 provide an I2C bus capable of communication at
up to 1 MHz. Pull-up resistors of approximately 2 K arerequired on both...