MazeSolverProject is a PlatformIO-based embedded system project designed to efficiently solve mazes using optimized FloodFill algorithms. The project is built for a maze-solving robot equipped with:
- 4 HC-SR04 ultrasonic sensors (front, right, back, left) for obstacle detection.
- MPU6050 IMU sensor for dead reckoning and odometry-based movement.
- Custom movement logic for precise control, accurate turning, and movement optimization.
This system is designed to operate autonomously in a maze, accurately mapping walls and computing the shortest path to the goal using a FloodFill algorithm with optimizations. This was built for the 2023 Technoxian World Robotics Championship 2023 under team RoboManipal.
- Optimized FloodFill Algorithm for efficient path planning.
- HC-SR04 Ultrasonic Sensor Integration for real-time obstacle detection.
- IMU-based Odometry using an MPU6050 for accurate movement tracking.
- Dead Reckoning Capabilities for position estimation.
- Custom PID-based Movement Control ensuring precision in turns and navigation.
- Modular Design for easy modification and adaptation to different robotic platforms.
- PlatformIO Support for streamlined development and deployment.
MazeSolverProject/
│── include/ # Header files for classes and functions
│── src/ # Source files implementing maze-solving algorithms
│── lib/ # Custom libraries (MazeBot, Sensor Integration)
│── test/ # Test cases for verifying correctness
│── platformio.ini # Configuration file for PlatformIO
│── images/ # (Optional) Contains an image of the robot
- Motors: Two independent drive motors (left and right) for movement.
- Ultrasonic Sensors: Four HC-SR04 sensors for distance measurement.
- IMU Sensor: MPU6050 for accurate angle measurement and dead reckoning.
- Microcontroller: Compatible with ESP32 or similar embedded controllers.
This project requires the following dependencies:
- PlatformIO: A development platform for embedded systems.
- Arduino Framework: Provides essential libraries for Arduino-based development.
- Wire Library: For I2C communication with the MPU6050.
These dependencies are managed through the platformio.ini configuration file.
To set up and run the MazeSolverProject:
-
Clone the repository:
git clone https://github.com/TarunMurugan/MazeSolverProject.git
-
Navigate to the project directory:
cd MazeSolverProject -
Open the project using PlatformIO:
- If using VS Code, install the PlatformIO extension and open the project folder.
- If using the CLI, navigate to the project directory and run:
platformio run
-
Build the project:
platformio run
-
Upload to target hardware (if applicable):
platformio run --target upload
- The bot initializes by calibrating its MPU6050 IMU.
- It then begins scanning the environment using ultrasonic sensors.
- Wall mapping is performed using sensor data, and the FloodFill algorithm is executed to navigate the maze.
- The bot autonomously moves through the maze while optimizing movement based on PID control.
- The bot maintains an odometry log using IMU data for precise movement tracking and dead reckoning.
The lib/ folder contains a custom-built MazeBot library that integrates:
- Ultrasonic sensor handling
- IMU-based motion control
- Movement commands (forward, turn left, turn right)
- Wall detection logic
An image of our bot:
Credits: Team Robomanipal
