Why not power a motor from Arduino?

Please note that the question in the post title is not intended as a challenge to the conventional wisdom, it is literally a request for explanations that can help me improve my current understanding. So this post is mostly a question about why certain things should or should not be done.

For example, I recently saw this comment by @LarryD in another thread:

Although this post is primarily about the first half of the above statement, I'm also curious about the blanket statement about never powering a motor from a 9V battery. Is it because common hobbyist DC motors are designed for operation at 3-6V, and a 9V supply would shorten the motor lifespan? Or is it because 9V batteries have unfavorable characteristics under current loads produced by a motor?

On to the big no-no: powering a DC motor from an Arduino. I understand that part of the concern is exceeding the maximum current limit for the Arduino power rail. But if that was the only concern, then it should be OK to power a small DC motor (stall current <1A) using something like an Arduino UNO R4 that is USB-powered (maximum current draw from 5V pin rated at 2A).

Forum search led to an old comment by @Robin2, stating:

*I inserted the word "no" into the quote above β€” as I'm fairly sure this is what was intended by @Robin2.

So the first of the two concerns raised in the above comment should not disqualify the use of the 5V pin, if the motor stall current is lower than the maximum allowed current draw. Thus, if that condition is met, then the primary concern seems to be "voltage spikes that a motor creates".

Can someone provide an explanation of this? Is this a just a reference to the induced voltage generated in the armature coil when switching the motor off? And if so, could this risk not be mitigated using a fly-back diode? Are there also other types of voltage spikes that one should be concerned about, and if so, what are they? For context, at this time, I am mostly interested in brushed DC motors, so I would like to learn about voltage spike issues in such motors.

A related question would be: are the same "voltage spike" concerns present if the motor were powered by proper power supply (not the Arduino), but one decided to also power the Arduino board using that same voltage supply?

I have more questions, but I'll wrap up the post for now. Again β€” I would like to stress that I am just seeking to better understand the rationale behind the various recommendations given. Technical explanations would be very welcome.

Thank you!

Both.

it should be OK to power a small DC motor (stall current <1A) using something like an Arduino UNO R4 that is USB-powered (maximum current draw from 5V pin rated at 2A.

Not from an electrical noise point of view. It can be severe, causing the processor to malfunction, digital inputs to give false readings, etc. You would need to add decoupling (noise reduction) circuitry.

This is all very basic electrical engineering theory: volts, amps, watts, RLC component behavior.

1 Like

Thank you for your response.

I am not an electrical engineer, but I would consider myself competent in all of the above β€” yet none of the 4 subject areas listed above would (on their own) explain "electrical noise" in the context being discussed. What is the specific source of this "electrical noise", and what makes it "severe"?

Hi, @grb

Another reason is the controller's PCB tracks would not be wide or have enough cross-section to carry that current without generating heat and causing losses in power. Ohms Law.

When you have significant current from an outside load, drawing say USB power through a controller PCB, as @jremington has said EMR and voltage drop can cause resets or noise on low level analog input signals.

Best to supply 5V loads directly from a 5V source so no load current flows through the controller.

Tom.... :smiley: :+1: :coffee: :australia:

Do your web searching and reading. One practical place to start is here: Pololu - 9. Dealing with Motor Noise

yet none of the 4 subject areas listed

RLC component behavior, the fourth subject area listed, is the central issue in both electrical noise generation (L voltage spikes, LC oscillations) and electrical noise reduction (RLC filters). Introductory EE courses cover this thoroughly in the first year of study.

Hi, @grb
This sort of power topography can be considered when connecting many loads, sensors, motors, LEDs etc.
In this case Load 2 and LOAD 3 , could be sensors and LEDs. and can share a common power supply system.
Load 1, could be a motor, stepper or servo and it would be connected to the power supply with its own pair of power wires, this helps prevent the load current effecting the other load currents and thus their outputs.

The bypass capacitors, may be needed in the case of long power leads or close proximity of the leads to each other.

Anyone feel free to edit etc, just a graphical explanation.

Tom.... :smiley: :+1: :coffee: :australia:

@TomGeorge Thank you for your responses.

I don't disagree with this, and the purpose of my post was not to ask you to convince me that this is the best approach (I already am convinced) β€” as stated in my post, I am requesting specific, detailed explanations for the underlying reasons why this is the conventional wisdom.

I understand that this phenomenon could limit the amount of current that is possible to draw from a PCB, but surely the User Manual would not state that it is OK to draw 2A from the 5V pin if it is not possible to draw 1A without causing deleterious voltage drops in the PCB tracks?

Assuming EMR = Electromagnetic Radiation, wouldn't this be present whether the motor is powered from the Arduino or has its own dedicated power supply?

Thank you, again β€” this is helpful practical advice. However, in this thread, was looking for something else.

Practical advice was not what I was looking for here, but thank you, nonetheless.

From the linked Pololu article:

The main source of motor noise is the commutator brushes, which can bounce as the motor shaft rotates. This bouncing, when coupled with the inductance of the motor coils and motor leads, can lead to a lot of noise on your power line and can even induce noise in nearby lines.

The above quote does provide a key piece to the puzzle.

All I said was that the topics you mentioned would not "on their own" explain electrical noise in motors. The Pololu article confirms that the root cause of noise in DC motor power lines is the bouncing of commutator brushes.

No argument there.

So based on the information provided so far, the answer to my main question seems to be that the main reason why a motor should not be powered from an Arduino is that commutator brush bouncing causes noise injection into the power rails.

I'm actually surprised that the main concern raised in the responses was not the voltage that would be induced when the motor is switched off...

That is not true. Those four fundamental topics and the relations between them do, in fact, explain the basics.

When current changes rapidly in a circuit (as when brushes bounce or switches open), circuit inductance directly causes the observed voltage spikes.

The physical principle behind this is basic equation defining inductance L


 V = L * (rate of change of current dI/dt)

which you can think of as a non-steady state version of Ohm's Law.

If you don't want "practical advice" you have no choice but to learn the basic theory.

1 Like

The manual is probably quoting on the active components on the PCB and not the actual PCB mechanics.
Which controller is this reference to, can you please post a link.
Some of the later controllers have SMPS/DC-DC converters on them, others linear regualtors.

Tom.... :smiley: :+1: :coffee: :australia:

Arduino UNO R4 WiFi. Here's the link:

Not sure what makes you think that I don't already know the "basic theory". I am just not familiar with all the esoteric knowledge of how real-life systems deviate from the ideal models that are used in "basic theory" (such as bouncing brushes). To quote another informative article from the Pololu site:

As with many unexpected problems that we encounter in electronics, the causes ... are the non-negligible parasitic elements of the components we try to idealize.

It is precisely the deviations from idealized models that require a significant amount of training (beyond the first few years of an undergraduate EE curriculum, even) to get acquainted with.

From this page:-
Uno R4 Wifi

It says:-

Maximum current draw per pin: the UNO R4 series' maximum current draw per GPIO is 8 mA, which is significantly lower than previous versions. Exceeding this limit may damage your pin / board.

Did you miss that?

You seem to me mixing up powering the module with what the pins can give.

1 Like

When powered via the VIN pin, you are using the onboard regulator to bring down the voltage to 5V, which means that the 5 V pin can provide up to 1.2 A. Keep in mind that this voltage regulator also powers the rest of the circuit board, including the MCU, LEDs among other components.

The ISL854102FRZ-T Buck Converter IC is rated at 1.2A.

Glad that you looked for the spec, a lot of builders don't.

Have you had a look at the controller PCB to find the tracks?

Tom.... :smiley: :+1: :coffee: :australia:

I think it is important to realize that a rule of thumb provided for beginners is not necessarily a hard truth that must be observed by people expert in the field.

The actual hard rule is "you must not exceed the parameters of the Arduino if you want reliable operation in all operating conditions" which includes all the things like current draw, heat dissipation, ambient temperature, voltage spikes, electrical noise etc. However, beginners don't have the knowledge to assess all those parameters and tell if they are likely to be exceeded. Hence, the simple rule for beginners.

1 Like

Tom,

In our case, we are powering using USB, and therefore by-passing the buck converter.

Yes, it looks like the 5V track has a width of 0.5mm, so assuming a 35-ΞΌm thickness, this would have a resistance of around 1* 0.01 Ξ©/cm β€” i.e., a 1-A current draw at motor stall would cause a gradient of dV/dx = –1* –0.01 V/cm. At rated motor loads, it would be less than 25% of that.

The resulting drop should be in the path from the USB connector to the 5V-pin, which I am not having much luck tracing in the PCB CAD, but appears to have an overall length of around 6 cm. Thus, assuming VUSB=4.7V after the Schottky diode drop, I'm guesstimating that the 5V-pin would see around 3.2V* 4.68V under typical motor operating conditions (but may drop to 0V* 4.64V if the motor stalls).

The R7FA4M1AB3CFM#AA0 data sheet specifies a minimum VCC value of 1.6V (or as high as 3.8V when the on-chip USB-2.0 host controller is used in full-speed mode, and with the USB Regulator enabled). In our case, no USB transfer is occurring while the motor is being used.

If my assumptions and measurements are reasonably correct, then it is clear that major problems with board operation could occur if the motor stalls, but that* the expected voltage drop in the PCB traces under permissible motor loads (current draw lower than the max rated value of 250mA) may not actually cause significant issues (in this particular case).


*Edited to correct unit conversion error, and delete a faulty conclusion, as clarified below.

No, Grumpy Mike, I did not miss that. I am not asking about what would happen if one were to drive a motor directly from a GPIO pin. This post is about understanding the potential repercussions of using the Arduino 5V pin as a supply for the motor power (VM).

I think your resistance calculation is way off

The motor is stalled every time you apply power as it is starting from a standing start. Assuming your calculations are correct (they don't seem right but I've not checked them) you'd get the drop to 0V every time the motor is started.

And dissipate 1W in that very thin track, make a nice little heater.

EDIT
I did the calculation for the track and it comes out at 0.00952Ξ© / cm
https://www.allaboutcircuits.com/tools/trace-resistance-calculator/

I'm curious to know how you got 1Ξ©.

This is starting to look like an X-Y problem, the real question seems to be how to power an Arduino and a motor from a single USB-C port.

2 Likes