DC Motor Speed Control Using Arduino PWM and TIP122 Transistor — Ultimate Student Project Guide ⚙️🚀

DC Motor Speed Control Using Arduino, PWM, and TIP122 Transistor with LCD Display

In this tutorial, we’ll guide you through an innovative engineering project to control the speed of a high RPM DC motor using PWM (Pulse Width Modulation) with an Arduino Uno, a TIP122 transistor, and a 16×2 LCD display. This project is designed for engineering students and hobbyists seeking hands-on experience with Arduino and electronics. By the end of this project, you’ll understand how to regulate motor speed through PWM and display real-time duty cycle information on an LCD screen, making this project an excellent choice for competitions, academic presentations, and skill-building.


🧠 Introduction

Welcome to our detailed tutorial on DC Motor Speed Control Using Arduino PWM where we will build a practical project to control the speed of a high-RPM DC motor using an TIP122 transistor, an Arduino Uno and a 16×2 LCD display. 🎯 This project is ideal for engineering students and hobbyists who want hands-on experience with electronics, microcontrollers and motor control automation. We’re going to show you how you can regulate motor speed through PWM and display real-time duty cycle feedback on the LCD.

⚙️ Project Objective & Overview

The main aim of this project is to implement DC Motor Speed Control Using Arduino PWM in a simple and educational way. This solves the common requirement of controlling motor speed in robotics, automation systems, cooling fans, conveyor belts or lab-demonstrations. The target audience is college students, hobbyists and educators who want a compact yet effective project. In summary: using Arduino to read a potentiometer, map that to a PWM duty cycle, drive a DC motor via TIP122, and display the duty cycle on a 16×2 LCD.

🧩 Components Used

ComponentShort DescriptionFunction
Arduino Uno8-bit microcontroller boardReads input & generates PWM
TIP122 TransistorNPN Darlington transistorSwitches motor current as driven by Arduino
High RPM DC MotorMotor whose speed is controlledThe load whose speed we regulate
16×2 LCD DisplayLCD moduleDisplays real-time duty cycle feedback
PotentiometerVariable resistorUser input to vary duty cycle
Breadboard & Jumper WiresPrototyping toolsEnable quick wiring and changes

🪄 How the Project Works (Step-by-Step Explanation)

Here’s the step-by-step logic behind DC Motor Speed Control Using Arduino PWM:

  1. User turns the potentiometer connected to the Arduino analog pin.
  2. Arduino reads analog value (0-1023) from the potentiometer.
  3. That value is mapped to a PWM output value (0-255) using map() function.
  4. The duty cycle as a percentage (0-100%) is derived from the PWM range.
  5. Arduino outputs PWM on one of its PWM-capable pins (e.g., pin 5).
  6. The TIP122 transistor is arranged as a switch: base driven by the PWM pin (via current‐limiting resistor) → collector connected to motor + supply, emitter to GND. The transistor handles higher current for the motor that Arduino cannot. Electrical Engineering Stack Exchange
  7. The motor speed varies according to the average voltage/power produced by the PWM signal (higher duty cycle → faster rotation).
  8. Meanwhile, the LCD is initialized and displays a static title (e.g., “DC Motor Control”) on line 1, and dynamic duty cycle on line 2.
  9. A short delay (200 ms) provides stability and avoids excessive flicker of display.
  10. The loop continues, allowing the user to vary the potentiometer and see live feedback of duty cycle and motor speed for DC Motor Speed Control Using Arduino PWM.

🔌 Circuit Diagram / Block Diagram

Here is your diagram placeholder for DC Motor Speed Control Using Arduino PWM:
— ALT: DC Motor Speed Control Using Arduino PWM Circuit Diagram
— ALT: Block-diagram for DC Motor Speed Control Using Arduino PWM

Wiring Table

Pin/ConnectionConnectionComment
PotentiometerOne end → 5 V, other end → GND, wiper → A0 (Arduino)User input to vary duty cycle
Arduino pin 5 (PWM)To base of TIP122 via ~1kΩ resistorPWM output for motor control
TIP122 emitterGNDTransistor switched-ground reference
TIP122 collectorOne terminal of DC motorMotor drive switching element
Other terminal of motor+V supply (e.g., 12 V)Motor power supply
16×2 LCD rs,en,d4,d5,d6,d7rs → 7, en → 8, d4 → 9, d5 → 10, d6 → 11, d7 → 12 (Arduino)Display duty cycle & text
LCD Vss,Vdd,VeeVss → GND, Vdd → 5 V, Vee → Potentiometer (for contrast)Typical LCD wiring
Arduino GNDGND common with motor supply and TIP122 emitterEnsure common ground
Flyback diodeAcross motor terminals (reverse‐bias)Protect transistor from motor back-EMF (recommended) Electrical Engineering Stack Exchange+1

💻 Arduino / Embedded Code

#include <LiquidCrystal.h>

// LCD pin setup
const int rs = 7, en = 8, d4 = 9, d5 = 10, d6 = 11, d7 = 12;
LiquidCrystal lcd(rs, en, d4, d5, d6, d7);

// Define pins
const int potPin = A0;    // Potentiometer connected to analog pin A0
const int motorPin = 5;   // PWM pin connected to the base of TIP122 (via a resistor)

// Variables
int potValue = 0;         // To store the potentiometer value
int dutyCycle = 0;        // To store the calculated duty cycle (0-100%)

void setup() {
  // LCD initialization
  lcd.begin(16, 2);
  lcd.setCursor(0, 0);
  lcd.print("DC Motor Control");

  // Set the motor pin as output
  pinMode(motorPin, OUTPUT);
}

void loop() {
  // Read potentiometer value (0-1023)
  potValue = analogRead(potPin);

  // Map the potentiometer value to a duty cycle (0-255 for PWM)
  int pwmValue = map(potValue, 0, 1023, 0, 255);

  // Calculate duty cycle as a percentage
  dutyCycle = map(pwmValue, 0, 255, 0, 100);

  // Output PWM signal to motor
  analogWrite(motorPin, pwmValue);

  // Display duty cycle on the LCD
  lcd.setCursor(0, 1);
  lcd.print("Duty Cycle: ");
  lcd.print(dutyCycle);
  lcd.print("%   "); // Extra spaces to clear old data

  delay(200); // Short delay for stability
}

Code Walkthrough (student friendly):

  • We include the LiquidCrystal library to control the LCD.
  • We define which Arduino pins connect to the LCD (rs, en, d4–d7).
  • We setup the potentiometer pin (A0) and motor pin (5 – a PWM pin).
  • In setup() we initialize the LCD and print the title. We also set the motor pin as an output.
  • In loop() we read the potentiometer value (0–1023).
  • We map that value to 0–255 because analogWrite() accepts 0–255 for PWM.
  • We also calculate the duty cycle percentage (0–100%) from that PWM value for display.
  • We apply the PWM to the motor pin, which drives the TIP122 transistor, which in turn drives the motor.
  • We update the LCD to show “Duty Cycle: XX%”. The extra spaces clear any leftover digits.
  • We wait for 200 ms to avoid flickering or too-rapid updates.
  • Then the loop repeats, so the user can continuously vary the potentiometer and see the effect.

🎥 Project Demonstration Video

🎬 Hindi Demonstration 👇

🎬 English Demonstration 👇


📦 Related Product Link

👉 Buy Fully Assembled DC Motor Speed Control Using Arduino PWM Kit from Circuits Bazaar

📈 Applications

  • Hands-on demonstration for engineering lab on motor control & PWM.
  • Automation projects: conveyor belts, fan speed control, robotic joints.
  • DIY hobbyist platforms: variable speed vehicles, RC variants, model assemblies.
  • Teaching electronics and embedded systems concepts in schools/universities.
  • Student competition projects showcasing real-time display and control.

🌱 Advantages

  • Offers precise control of motor speed via PWM rather than analog voltage.
  • Affordable and uses widely-available components (Arduino Uno, TIP122, LCD).
  • Provides real-time feedback (duty cycle shown on LCD) which enhances learning.
  • Suitable for beginners to intermediate learners – solid foundational project.
  • Expandable for further enhancements: sensors, wireless control, multiple motors.

⚠️ Limitations

  • TIP122 transistor has power/current limits; not suited for very high-power motors unless upgraded (e.g., use MOSFET).
  • Motor noise or jitter may occur at low duty cycle due to limited torque.
  • Without proper fly-back diode, motor back-EMF could damage components — must ensure protection.
  • The system doesn’t include closed-loop feedback (e.g., RPM measurement) — open-loop control only.

Mitigations: Use MOSFET driver for higher current, add diode & capacitor across motor for protection, consider adding tachometer if closed-loop control is required.


🚀 Future Scope & Enhancements

  • Add PID control or closed-loop RPM feedback using a tachometer or encoder to make the motor maintain a set speed.
  • Integrate wireless modules (Bluetooth/WiFi) to remotely adjust speed or monitor the duty cycle.
  • Extend to multi-motor control for robotics or conveyor systems.
  • Incorporate IoT/cloud data logging of duty cycle and motor speed for analytics.
  • Use higher-power transistor/MOSFET and design PCB to commercialize the solution.
  • Add direction control (H-bridge) to support forward/reverse functionality.

🔗 Internal Resource Links


📚 References / Further Reading


🌐 External Reference (DoFollow)

👉 Arduino Official Guide – Transistor Motor Control

❓ Frequently Asked Questions

Q1. What is the working principle of the DC Motor Speed Control Using Arduino PWM project?

💡 The project works on the PWM (Pulse Width Modulation) principle. The Arduino adjusts the width of the digital pulses sent to the TIP122 transistor, which controls the average voltage supplied to the DC motor. As the duty cycle increases, the motor spins faster; as it decreases, speed reduces.

Q2. Can this DC Motor Speed Control Using Arduino PWM project be customized for college submissions or advanced use?

⚙️ Yes! Students can add features like Bluetooth control, IoT-based remote monitoring, or an RPM sensor for closed-loop feedback. These enhancements improve functionality and make the project competition-ready.

Q3. What are the essential components used in the DC Motor Speed Control Using Arduino PWM setup?

🔩 The core components are an Arduino Uno microcontroller, TIP122 transistor, 16×2 LCD display, potentiometer, and a high-RPM DC motor. Together, they enable input reading, PWM signal generation, and real-time display of the duty cycle.

Q4. What is the future scope of the DC Motor Speed Control Using Arduino PWM project?

🚀 The system can be upgraded with RPM feedback, PID control for precise speed regulation, or cloud integration to log motor performance data. It can also be expanded for multi-motor applications in robotics and automation.

Q5. Is the DC Motor Speed Control Using Arduino PWM project beginner-friendly?

✅ Absolutely! It’s ideal for beginners to learn Arduino programming, PWM concepts, and basic motor electronics. With minimal components and clear code, students can complete it quickly and gain solid hands-on experience.

Leave a Reply

Your email address will not be published. Required fields are marked *