Arduino RC Car Circuit Using Arduino Uno and L293D (4WD Model)

 

RC CAR CIRCUIT USING L293D MOTOR DRIVER

Introduction

This project demonstrates how to build a 4-Wheel Drive (4WD) RC Car using the Arduino Uno and two L293D motor driver ICs.

Each L293D controls two DC gear motors, allowing independent control of:

  • Left Front (LF)

  • Left Rear (LR)

  • Right Front (RF)

  • Right Rear (RR)

The entire project can be simulated in Tinkercad and serves as the base for:

  • Bluetooth RC Car

  • Obstacle Avoiding Robot

  • Line Following Robot

  • IoT Smart Car


 Project Objective

To design a 4WD robotic car chassis using Arduino that can:

  • Move Forward

  • Move Backward

  • Turn Left

  • Turn Right

  • Stop


 Components Required (Tinkercad)

  • 1 × Arduino UNO

  • 2 × L293D Motor Driver IC

  • 4 × DC Gear Motors

  • 1 × Breadboard

  • External Power Supply (6–9V)

  • Jumper Wires


 Circuit Description

 L293D #1 (Left Side Motors)

  • OUT1 & OUT2 → Left Front Motor

  • OUT3 & OUT4 → Left Rear Motor

Control Pins:

  • IN1 → Arduino Pin 2

  • IN2 → Arduino Pin 3

  • IN3 → Arduino Pin 4

  • IN4 → Arduino Pin 5

  • EN1 & EN2 → 5V (or PWM for speed control)


🔹 L293D #2 (Right Side Motors)

  • OUT1 & OUT2 → Right Front Motor

  • OUT3 & OUT4 → Right Rear Motor

Control Pins:

  • IN1 → Arduino Pin 6

  • IN2 → Arduino Pin 7

  • IN3 → Arduino Pin 8

  • IN4 → Arduino Pin 9

  • EN1 & EN2 → 5V


 Power Connections (Both ICs)

  • Vcc1 (Logic) → Arduino 5V

  • Vcc2 (Motor Supply) → External 6–9V

  • GND → Arduino GND (Common Ground Required)

Always ensure common ground between Arduino and motor supply.


 How L293D Motor Driver Works

  • L293D is a dual H-Bridge motor driver IC.

  • It allows motors to rotate in both directions.

  • By changing input logic (HIGH/LOW), we control direction.

  • Enable pins allow speed control via PWM.


 Arduino Code for Basic Movement

int LF1 = 2;
int LF2 = 3;
int LR1 = 4;
int LR2 = 5;

int RF1 = 6;
int RF2 = 7;
int RR1 = 8;
int RR2 = 9;

void setup() {
pinMode(LF1, OUTPUT);
pinMode(LF2, OUTPUT);
pinMode(LR1, OUTPUT);
pinMode(LR2, OUTPUT);
pinMode(RF1, OUTPUT);
pinMode(RF2, OUTPUT);
pinMode(RR1, OUTPUT);
pinMode(RR2, OUTPUT);
}

void forward() {
digitalWrite(LF1, HIGH); digitalWrite(LF2, LOW);
digitalWrite(LR1, HIGH); digitalWrite(LR2, LOW);
digitalWrite(RF1, HIGH); digitalWrite(RF2, LOW);
digitalWrite(RR1, HIGH); digitalWrite(RR2, LOW);
}

void backward() {
digitalWrite(LF1, LOW); digitalWrite(LF2, HIGH);
digitalWrite(LR1, LOW); digitalWrite(LR2, HIGH);
digitalWrite(RF1, LOW); digitalWrite(RF2, HIGH);
digitalWrite(RR1, LOW); digitalWrite(RR2, HIGH);
}

void left() {
digitalWrite(LF1, LOW); digitalWrite(LF2, HIGH);
digitalWrite(LR1, LOW); digitalWrite(LR2, HIGH);
digitalWrite(RF1, HIGH); digitalWrite(RF2, LOW);
digitalWrite(RR1, HIGH); digitalWrite(RR2, LOW);
}

void right() {
digitalWrite(LF1, HIGH); digitalWrite(LF2, LOW);
digitalWrite(LR1, HIGH); digitalWrite(LR2, LOW);
digitalWrite(RF1, LOW); digitalWrite(RF2, HIGH);
digitalWrite(RR1, LOW); digitalWrite(RR2, HIGH);
}

void stopCar() {
digitalWrite(LF1, LOW); digitalWrite(LF2, LOW);
digitalWrite(LR1, LOW); digitalWrite(LR2, LOW);
digitalWrite(RF1, LOW); digitalWrite(RF2, LOW);
digitalWrite(RR1, LOW); digitalWrite(RR2, LOW);
}

void loop() {
forward();
delay(3000);
left();
delay(2000);
right();
delay(2000);
backward();
delay(3000);
stopCar();
delay(2000);
}

Movement Logic Summary

ActionLeft MotorsRight Motors
ForwardForwardForward
BackwardReverseReverse
LeftReverseForward
RightForwardReverse
StopOFFOFF

 Learning Outcomes

Students will understand:

  • H-Bridge motor control

  • Direction control logic

  • Multi-motor coordination

  • Robot chassis movement principles

  • Real-world robotics applications



BEGINNER PROJECTS (Foundation Skills)

  1. Ultrasonic Distance Measurement
  2. Traffic Light Simulation with 7-Segment Display
  3. 7-Segment Display Counter
  4. Kids Piano Circuit (8-Key Version)
  5. 16×2 LCD Display with Text Output
  6. LCD I2C to Arduino UNO
  7. Temperature Measurement using Arduino UNO
  8. LDR Controlled Street Light

INTERMEDIATE PROJECTS (Build Your Skills)

  1. Servo Motor Control Using Potentiometer
  2. DC Motor Speed Control
  3. Temperature Controlled Fan
  4. PIR Based Theft Alert System
  5. LPG Gas Leakage Detection System
  6. Automatic Door Locking System
  7. Soil Moisture Based Automatic Watering System
  8. Simple Digital Clock using Arduino UNO
  9. Automatic Voting Machine (EVM)
  10. Joystick Control using Arduino Uno
  11. RGB Lamp Control using Arduino Uno

    ADVANCED PROJECTS (Master Level)

    1. Home Automation Using Arduino UNO
    2. Bluetooth RC Car using Arduino Uno
    3. Obstacle Avoiding Robot
    4. Line Follower Robot
    5. Radar System Using Arduino UNO
    6. Automatic Parking System
    7. Bi-Directional People Counter using Arduino Uno 
    8. Automatic Plant Watering System
    9. NeoPixel LED Ring Control using Arduino Uno
    10. Smart Gloves for Bedridden People

      ROBOTICS & MOTION PROJECTS

      1. RC Car Using L293D Motor Driver
      2. Robot Arm and Leg Control Using Servo
      3. Smart Irrigation System using Arduino Uno


      Comments