Arduino Motors and Transistors

This week, we’ll finally be using the Arduino to control some motors! First up, we’ll control a standard DC motor running off a 9V battery with the help of an NPN transistor and a PWM (Pulse Width Modulated) signal from the Arduino.

Arduino Motors and Transistors


Thanks to Jeremy , for this articles


Next, it’s onto 180 degree servo motors, which we will power on an independent 5V rail using a voltage regulator. We’ll control the servo using a PWM signal from the arduino, and I’ll show you how you can turn analog distance readings into precise angles for the servo to turn to!

I mention in the video that you can control DC motor direction using an H-Bridge. If you want to wire that up, take a look through this Wikipedia article, and read through this tutorial.

If you want to learn more about analog input filtering in software, check out this example code.

The Arduino Contest has been extended! So don’t forget to submit your project.

 Arduino Motors and Transistors Schematic

You can download the files associated with this episode here:


Major Components in Project

1.   Arduino Uno: -board/dp/13T9285
2.   USB Cable: http://us .element –
3.   Arduino Software:
4.   Breadboard: h ttp://us.element
5.   .1uF capacitor: elec -0- 1%C2%B5f-50v-radial/dp/65R3169
6.   22uF capacitor: elect -22uf -50v-radial/dp/38M6812
7.   5V Regulator:
8.   9V Battery Clip: -3449/battery-clip- 9v -wire -lead/dp/34M2183
9.   NPN Transistor:
10.  1k ohm Resistor: -0 -25w -1k/resistor-carbon – film -1kohm -250mw/dp/38K0327
11.  1uF Capacitor: -bc -components/ k105z205ve5th5/capacitor -ceramic-1uf-25v5v-radial/dp/95C0982
12.  1N4004 Diode: -general- semiconductor/1 n4004 – e3- 54/standard-diode-1a -400v -do-204al/dp/78K2126
13.  IR Distance Sensor: http://us.element-
14.  Geared DC Motor:
15.  Servo Motor:
16.  Jumper Kit: 

READ  Bug-Catching Spider in Web using Arduino Part 2

For more detail: Arduino Motors and Transistors

This Post / Project can also be found using search terms:

  • 14N9318
  • arduino motor transistor

Leave a Comment

= 3 + 2

(Spamcheck Enabled)

Read previous post:
Logic Analyzer
Oscilloscope / Logic Analyzer using Arduino

One of the frustrating things about developing and debugging electronic circuits is that you can't look inside the circuit to...

Scroll to top