Powering motors

Choose batteries, split motor and logic power, share a common ground and avoid brownouts on your Pico robot.

By Kevin McAleer,    5 Minutes

Page last updated November 24, 2026


Course Cover Image


By the end of this lesson you will be able to power a Pico robot from two supplies joined by a common ground, and explain what a brownout is and how to prevent one.

Most “my motor code is broken” problems turn out to be power problems. This lesson is short, but it will save you the most debugging time of the whole course.

Two supplies, one ground

Scout has two kinds of load. The Pico and sensors need a clean, steady 3.3 V. The motors need lots of current and make electrical noise. We give them separate supplies and join them at ground:

flowchart LR
    USB["USB or regulated 5V"] --> PICO["Raspberry Pi Pico"]
    PICO -->|"GPIO signals"| DRV["Driver logic inputs"]
    BAT["4xAA battery pack"] -->|"motor current"| SUP["Driver motor supply"]
    PICO --- GND["Common ground"]
    DRV --- GND
    BAT --- GND

The common ground is essential. Signals are voltages measured relative to ground, so if the Pico and the driver do not share a ground wire, the driver has no idea what a “1” from the Pico means. Wheels twitching randomly is the classic symptom.

Choosing batteries

Battery Voltage Notes
4xAA alkaline about 6 V fresh Easy and safe, but voltage sags under load
4xAA NiMH rechargeable about 4.8 V Strong under load, ideal for TT motors
1S LiPo 3.7 V Compact and powerful, needs a proper charger
2S LiPo 7.4 V Too much for TT motors without limiting, handle with care

TT motors are happy at 3 to 6 V, so a 4xAA pack is a great starting point.

Battery safety, briefly: if you use LiPo cells, charge them with a LiPo charger, never leave them charging unattended, and stop using a puffy or dented cell. Do not short the leads. Use a pack with a built-in protection circuit when you can.

How much voltage reaches the motor?

Drivers lose some voltage as heat. An L298N drops roughly 2 V, while a DRV8833 drops a few tenths of a volt. That matters on a small battery:

# Voltage that actually reaches the motors (approximate)
battery_v = 6.0        # 4 fresh alkaline AA cells

l298n_drop = 2.0       # the L298N's bipolar outputs are lossy
drv8833_drop = 0.4     # modern MOSFET outputs are far more efficient

print("L298N motor volts:  ", battery_v - l298n_drop)    # 4.0
print("DRV8833 motor volts:", battery_v - drv8833_drop)  # 5.6

Four volts will still turn a TT motor, just more slowly and with a bigger dead zone. We will measure that dead zone in lesson 6.

Brownouts

A brownout is when the supply voltage dips so low that something resets. When a motor starts, it briefly draws several times its running current. A weak or shared supply sags, the Pico notices, and your program restarts in the middle of a move.

Prevention, in order of usefulness:

  1. Power the motors from their own battery, not the Pico’s 3V3 or VBUS pins
  2. Use a fresh or charged battery with enough current capacity
  3. Add a 100 uF capacitor across the motor supply near the driver
  4. Start motors gently (lesson 9)

Powering the Pico itself

While you learn, keep the Pico on USB. When Scout goes untethered, remember that the Pico’s VSYS input takes up to 5.5 V, so a fresh alkaline pack at 6 V is too high. Use NiMH cells, or a small 5 V regulator module between the pack and the Pico.

Try it Yourself

  1. Measure your battery pack with a multimeter, with and without a motor running. How much does it sag?
  2. Put the L298N’s logic jumper settings in your notes: is the 5V regulator jumper in place? (More on this in lesson 5.)
  3. Challenge: work out the stall current of both motors together, and check your battery pack can supply it.

Common Issues

  • Problem: The motors twitch or the driver ignores the Pico.
  • Solution: Connect a ground wire between the Pico and the driver.
  • Why: Without a shared reference, the driver cannot read the Pico’s signals.

  • Problem: The Pico resets when I start both motors at once.
  • Solution: Use a separate battery for the motors, add a capacitor, and ramp the speed up.
  • Why: The starting surge makes the supply voltage dip below what the Pico needs.

Teachers: AA packs, either alkaline or rechargeable NiMH, are the safest choice for a classroom. Keep LiPo cells for older, supervised learners: charge them only with a proper LiPo charger, never unattended, and never use a puffy or dented cell. Take the batteries out at the end of every session so a loose wire cannot short them in a bag.

Check your understanding

Quick quiz 1 of 3

Why must the Pico and the motor driver share a ground?

Quick quiz 2 of 3

Which driver loses about 2 V of the battery voltage as heat?

Quick quiz 3 of 3

A fresh 4xAA alkaline pack gives about 6 V. Why not connect it straight to the Pico’s VSYS?

< Previous Next >

Was this lesson helpful?

Course complete

Congratulations, you finished Motors and motor drivers!

That's all 17 lessons done. Let people know, it's a great way to inspire someone else to start.

Share card: I completed Motors and motor drivers on KevsRobots
Post Bluesky LinkedIn Facebook


What are you looking for?
Watch Videos Get Ideas Learn Something Read a Review Read the Blog Search
... Z Z z