IoT & Bluetooth-Controlled 4-Motor Car with Omni/Mecanum Wheels
The ADAS Car Control System is an ESP8266-based automated driving platform designed for real-time wireless control using a Bluetooth module (HC-05). The system drives four DC motors through L298N motor drivers to achieve omnidirectional movement (forward, backward, sideways, rotation).
This setup is particularly suitable for autonomous or semi-autonomous vehicle prototyping, robotics research, and educational purposes.
- Implement Bluetooth-based remote control using HC-05
- Drive 4 independent motors for omnidirectional movement
- Allow speed adjustment via Bluetooth
- Support multiple movement commands: forward, backward, sideways, rotation
- Provide a modular, maintainable motor control system
| Component | Description |
|---|---|
| ESP8266 NodeMCU | Main microcontroller |
| L298N Motor Driver (x2) | Drive 4 DC motors |
| DC Motors (x4) | Omnidirectional / Mecanum wheels |
| HC-05 Bluetooth Module | Wireless control interface |
| Power Supply | 7.4–12V for motors, 5V for ESP8266 |
Motor Connections:
- Motor 1 (Front Right): IN1 → D1, IN2 → D2, EN → D0 (PWM)
- Motor 2 (Front Left): IN1 → D3, IN2 → D4, EN → D5 (PWM)
- Motor 3 (Rear Left): IN1 → D6, IN2 → D7, EN → D8 (PWM)
- Motor 4 (Rear Right): IN1 → SD2, IN2 → SD3, EN → RX (PWM)
Bluetooth HC-05:
- TX → ESP8266 TX (GPIO1)
- RX → ESP8266 RX (GPIO3)
- VCC → 5V, GND → GND
-
Arduino IDE
-
ESP8266 Board Package
-
Required Libraries:
ESP8266WiFi.h(optional for future IoT extension)Arduino.h(built-in)
-
Bluetooth Input: The system continuously reads bytes from HC-05.
-
Command Parsing:
- Values 0–14 represent movement commands (forward, backward, sideways, rotate, stop, reserved).
- Values ≥16 adjust the motor speed (
wheelSpeed).
-
Movement Execution:
- A DCMotor class handles pin configuration, speed, and direction.
- Commands are executed through functions like
moveForward(),moveSidewaysRight(),rotateLeft(), etc.
-
Loop: After executing a command, the system waits for the next Bluetooth input.
Movement Commands Mapping:
| Command | Action |
|---|---|
| 0 | Stop |
| 1 | Right Forward |
| 2 | Forward |
| 3 | Left Forward |
| 4 | Sideways Right |
| 5 | Sideways Left |
| 6 | Right Backward |
| 7 | Backward |
| 8 | Left Backward |
| 9 | Rotate Left |
| 10 | Rotate Right |
| 11,12,14 | Reserved / Save |
The system’s architecture and control flow can be visualized here:
🔗 Block Diagram: View Block Diagram
Description:
- Bluetooth Module → Receives commands → ESP8266
- ESP8266 → Parses commands → Sets movement variable (
m) and speed - Motor Driver & Motors → Executes corresponding wheel movement
- Fully modular motor control via DCMotor class
- Support for omnidirectional movement
- Bluetooth-based wireless speed and movement control
- PWM speed adjustment
- Easy to extend for sensors (ultrasonic, IR) or IoT integration
- Ensure correct power supply for motors; do not power motors from ESP8266 5V.
- Motors and drivers should be isolated to prevent voltage spikes on ESP8266.
- Reserved commands (11, 12, 14) can be extended for future functions.
- Use adequate heat sinks for L298N drivers under continuous operation.
The ADAS Car Control System is a flexible, modular platform for studying autonomous vehicle dynamics, omni-directional control, and Bluetooth-based robotics.
It demonstrates hardware abstraction, real-time control, and modular code design, suitable for academic, hobbyist, or prototype autonomous vehicle projects.