/micromouse

A practical course at TU Munich to build a micromouse robot from scratch.

Primary LanguageC

Micromouse: Designing an Educational Racing - Robot from Scratch [TUM IN2106/IN4235]

A practical course at TU Munich to build a micromouse robot from scratch, led by Dr. Ph.D. Alexander Lenz. This repository serves as a collection of code and ressources during our group work of SS22. See the official course description for further information.

Content overview:

PCB

List of external Eagle libraries:

Name Usage
microchip-dspic33fjxxmc Microcontroller DSPIC33FJ64MC804
Eagle_WCAP-ATG5 (rev21a).lbr Electrolytic Capacitors
Eagle_WE-TIS (rev22a).lbr Inductances
Eagle_WE-XTAL (rev21c).lbr Oscillator Quartz Crystal
SamacSys_Parts.lbr Power Switch

Instructions for high-level maze solver

1) Allocate heap memory.

With the microchip compiler you have to allocate heap memory in the project properties (tutorial from Microchip). Use for example 4096 bytes.

2) If necesarry, adapt the settings of the high-level maze solver in src/settings.h.

  • MAZE_SIZE: Number of columns (= number of rows) of maze.
  • SIMULATION: Defines if simulation or real robot is used (used simulation: mms by mackorone).
  • VISUALIZATION: Defines if in simulation visualization should be used.

3) Only if you use the simulation: Rename main files.

Rename main.c to main_not_used.c (or any other name) and rename main_simulation.c to main.c.

4) Start high-level maze solver.

  • For simulation: Compile code and then follow the instructions of mms by mackorone.
  • For real-world Micromouse: Flash the compiled code onto the Micromouse robot and put the Micromouse into the starting position (bottom left corner of the maze, i.e. you have to place the mouse in one of the corners such that there is an outer wall of the maze on the left side of the mouse). Then turn the Micromouse on. After 10 seconds, it will automatically start exploring. After the exploration phase, it calculates and executes the shortest path from the starting cell to the center of the maze.

Some impressions

Finished Micromouse:
Finished Micromouse

6 x 6 maze to test the Micromouse:
Maze for testing

Testing the high-level maze solver in simulation:
High-level simulation