Author Options:

How to control speed motor dc 0-5000rpm with Arduino? Answered

Hello,  please I need help to control the speed of a dc motor with, for ex, Arduino.
I need it to set the rotate speed of a device that we use in I+D at the Uni. The roate speed that we use is between 0 to 5000 rpm. 
Any idea and help is more than welcome!!!!



3 years ago

How do you measure the shaft speed ?

What is the size of your motor (weight, voltage, peak current ) ?

Is it a motor with bearings ?

Hey I'm not testing you. I want to know how the TA does that measurment !

Answer that and I might find an easy way to accomplish your task or are a lurker only.


3 years ago

Just use PWM. The motor is probably higher current then an Arduino digital pin can supply, so you would have to use a single transistor (or MOSFET) or an H-Bridge. For an example of Arduino PWM output:

analogWrite(10, 255)

That code would send a 100% PWM output to pin 10, which would be controlling a transistor or H-Bridge, which in turn would be controlling power to the motor.

Use the servo library.

For university work, the rest has to be your efforts. Otherwise you are a cheat.


3 years ago

With a motor controller.

What can you find out about PWM control?

How much actual research have you done?