Cheap Electric Motor Speed Control ($10, 4HP, Arduino, PWM)

Introduction: Cheap Electric Motor Speed Control ($10, 4HP, Arduino, PWM)

About: I am an engineer focused on recycled batteries, electric vehicles and renewable energy. I am always working on engineering projects I can’t stop.

I am building the worlds most efficient production electric car. Please see the website at the link below.

I want this car to be inexpensive so everyone can afford one. For this reason I am designing and building my own cheap electric motor controller. My design is to use about 10 Mosfets with PWM controlled by an Arduino to efficiently control the speed of the 10 to 20 hp motor for the car.

This first section I tested has two Mosfets on the same heat sink. I was able to test it up to 20 amp and the Mosfets only heated up to 47C. If I increase the voltage to 48V at 20A I could control 1.3HP. This controller would be perfect for a large electric bicycle or small electric motorcycle and only costs about $10 in parts.

Parts list

Controller (I used an Arduino Mega but you can use a timer switch or other micro-controller)

2 Mosfets (I used N-channel 60Volts 30Amps FQP30N06L)

Diodes (I used 4 1N5404)

Head sink (I used a large finned aluminum heat sink)

Computer fan (I used a 12V .16A PC fan)

Wire (I used 18g but 16 or 14 would be better for the high amps, 22g for signal)


Step 1: Connecting Components

First I soldered wires to the Mosfet leads. I bent them apart carefully so that I had space to solder.

On the gate pin I soldered a 22g wire. On the drain and source I soldered 18g wire. I put heat shrink tubing over any exposed parts all the way up to the Mosfet.

I then connected the gates, sources and drains of both Mosfets. I connected them on the busbar. I attached a 22g wire to the drain on the bus bar. The gate and drain wires were connected to a bread board. A 1k resistor was used as a pull down resistor to discharge the gate when I was not powered. The gate was then connected to digital pin 13 on the Arduino. The drain was connected to the Arduino GND pin.

Then I connect a potentiometer to the Arduino to control the speed as well as an LCD screen (optional).

I bolted the Mosfets to the heat sink after applying some thermal paste to their backs.

Step 2: Arduino and Program

I used the Arduino digital pin 13 because it does PWM at about 1,000hz. The sound with most motors is pretty annoying but the frequency can be change if you want.

The program is very easy.

Just take in a variable from the analog pin measuring the pot. Then use this value to change the PWM duty cycle. Below is a small example of the program. The Pot uses the Arduinos 5 volt pin. The wiper on the Arduino has a voltage drop between 0 are 5 as you rotate it. The analog read function takes the voltage drop. We use this in the AnalogWrite function that will create the PWM pulses.

int PWM=13


AnalogWrite(PWM, Pot/4);

Step 3: Testing the Controller

I mounted a temperature gauge on one of the Mosfets and tested many different currents and monitored the temperature. I was able to run 17A for a long time and the temperature was stable at 47C. The max current was over 20A. I don't have any large motors so I used 4 12V motor and 4 light bulbs in parallel as the load. When I get my larger motor and build the larger battery pack I will start testing the larger controller for 10 to 20 Hp.

I used homemade lithium ion batteries to test my controller. I used 8 cells in parallel and up to 5 sets in series for 20V using 40 cells.

While testing around 20A I noticed my cells were getting very hot and had significant voltage sag.

MAKE ENERGY: A US-Mexico Innovation Challenge

Participated in the
MAKE ENERGY: A US-Mexico Innovation Challenge

Make it Glow!

Participated in the
Make it Glow!

Be the First to Share


    • Raspberry Pi Contest

      Raspberry Pi Contest
    • New Year, New Skill Student Design Challenge

      New Year, New Skill Student Design Challenge
    • Photography Challenge

      Photography Challenge



    hi friend! please if possible ,say to us how programin to control a 3 phase AC motor , is necessary an output(arduino) in 6 steps angle controled , end goes to the drive for 6 IGBT , this configuration control an 3 phase AC motor , in the analogical IN comes a potentiometer , this is to my electric car with a 3 phase AC motor (10 HP) , the batery is 96Volts , if necessary say in my gurgel2020 g gmail dot com , thanks ok


    7 years ago on Introduction

    Hi, a nice simple app for water pumps and such.

    Are you aware that the MOSFET you are using is not a logic level input device, that is, the MOSFET is designed for 20V, it does say a gate threshhold of 2.5V, however not a logic level type. So the 5V from the arduino will not necessarily turn the MOSFET to its minimum ON resistance.

    A logic gate MOSFET will run even cooler.

    A proper circuit diagram, and a working sketch would also enhance this demonstration.

    I suggest you do not connect the two gates together, use a 470R resistor in series with each gate and arduino output pin. The gate to source resistor on each MOSFET can be 10K.

    A good simple application for water pumps and fans, but needs just a little more info.