Return to Portfoliowebase.top / projects / maze-solving-car
Completed2025Role: Lead Embedded & Motor Control Programmer

Autonomous Maze-Solving RC Car

Arduino-Based Autonomous Mobile Robot with H-Bridge Actuation

An autonomous maze-solving vehicle engineered in C/C++ on Arduino, utilizing ultrasonic/IR distance sensors and an H-bridge motor driver for deterministic obstacle clearance and wall-following navigation.

1. The Engineering Problem

Autonomous navigation through unmapped, constrained physical mazes requires real-time obstacle detection, deterministic decision-making, and responsive motor actuation without relying on high-level compute or external GPS.

2. What Was Built

An Arduino-based robotic vehicle equipped with forward and lateral distance sensors. Motor control is executed through an H-bridge driver implementing variable PWM speed control, directional differential steering, and active braking.

3. System Architecture & Topology

ASCII Topology

Real-time sense-plan-act loop on an AVR microcontroller: distance sensor polling -> boundary evaluation -> differential motor commands.

Distance Sensors (Ultrasonic / IR)
              |
              v
Arduino Microcontroller (C/C++ Movement Logic)
              |
              v
H-Bridge Motor Driver (L298N / L293D)
              |
              v
DC Gearmotors (Forward / Reverse / Left / Right / Active Brake)

4. Mohamed's Personal Implementation

Wrote the core motion control logic in C/C++, handling sensor threshold evaluation and turn execution.
Implemented the H-bridge motor control routines with PWM duty cycle adjustments for precise turns and stall prevention.
Collaborated with the engineering team to debug physical wheel slip, sensor alignment, and turning delays.

5. Engineering Challenges & Solutions

Challenge: Sensor Noise Causing Erratic Wall Collisions
Solution: Implemented software median filtering over rolling distance samples, rejecting spurious ultrasonic reflections in tight maze corners.
Impact: Smooth, reliable wall navigation and maze resolution.

6. Technology Stack

Hardware
Arduino Uno / NanoL298N H-Bridge DriverUltrasonic HC-SR04DC Motors
Software
Embedded C / C++Arduino IDEState Machine Logic

7. Verified Outcomes

  • •Awarded 3rd Place in the official academy robotics competition.
  • •Verified autonomous completion of physical maze courses without manual intervention.