Skip to content
Tactiverge

Power systems and energy budgets

Voltage rails, current draw, the difference between peak and average power, and how to estimate how long a robot will run on its battery.

Lesson 2 of 6 · 35 min · Self-paced · Free

The question every mobile robot faces

"How long will it run?" is one of the first questions anyone asks about a mobile robot, and one of the easiest to get wrong. A robot that runs out of energy in the middle of a task, or whose computer resets every time the motors start, has a power problem, not a software problem. This lesson shows how to estimate a robot's power needs on paper before anything is built.

A few quantities

You may know some of these already; the embedded systems pathway covers them in more depth.

  • Voltage (V, volts) is the electrical "push".
  • Current (I, amperes or amps) is the rate at which charge flows.
  • Power (P, watts) is the rate at which energy is used: P = V × I.
  • Energy (watt-hours, Wh) is power multiplied by time. One watt for one hour is 1 Wh.

Battery capacity is often given in amp-hours (Ah) or milliamp-hours (mAh). To get energy, multiply by the battery's voltage: a 12 V, 6 Ah battery stores about 12 × 6 = 72 Wh. Comparing batteries in watt-hours avoids confusion when their voltages differ.

Voltage rails

Different parts of a robot want different voltages. Motors might run from 12 V, a small computer from 5 V, and a microcontroller and its sensors from 3.3 V. Each of these supplies is called a rail. The battery feeds the highest rail directly, and voltage regulators produce the lower ones.

Regulators are not free:

  • A linear regulator drops the extra voltage as heat. Its input current roughly equals its output current, so converting 5 V to 3.3 V at 0.15 A draws 5 × 0.15 = 0.75 W from the 5 V rail to deliver 3.3 × 0.15 ≈ 0.5 W. The other quarter of a watt becomes heat. Linear regulators are simple and quiet electrically, and fine for small currents.
  • A switching regulator converts voltage much more efficiently, often around 85–95%, by switching current on and off rapidly. Larger loads, like a single-board computer, normally use one.

Peak versus average

Robots do not draw a steady current. A motor starting from rest, or pushing against an obstacle, can draw several times its normal running current for a moment. A computer draws more while processing images than while idle.

Two different questions follow:

  • Average power decides run time: how quickly the battery's energy is used up.
  • Peak current decides whether the battery, wiring, fuses and regulators can cope at the worst moment. If the battery voltage sags too far during a motor surge, a regulator can drop out and the computer may reset — a classic and confusing fault.

A useful habit is to list every load with both an average and a peak figure.

Worked example: an energy budget

Here is a budget for a small two-wheeled robot with a single-board computer and camera. The numbers are made up for illustration, but are of a realistic size.

  • Battery: 12 V, 6 Ah. We plan to use only 80% of its energy, to protect it and leave a reserve.
  • Two drive motors on 12 V: 0.8 A each on average while driving, up to 3 A each at peak. The robot drives 60% of the time.
  • On the 5 V rail, from a 90%-efficient switching regulator: a computer (1.5 A average, 2.5 A peak), a camera (0.3 A) and a linear 3.3 V regulator for the microcontroller and sensors (0.15 A).
# Energy budget for a small two-wheeled robot (illustrative numbers).
BATTERY_V = 12.0
BATTERY_AH = 6.0
USABLE = 0.8              # plan to use only 80% of the stored energy
REG_EFFICIENCY = 0.9      # 12 V -> 5 V switching regulator

# Loads on the 5 V rail: (name, average amps, peak amps)
rail_5v = [
    ("single-board computer", 1.50, 2.50),
    ("camera", 0.30, 0.30),
    ("3.3 V linear regulator for MCU + sensors", 0.15, 0.15),
]
# Each drive motor runs straight from 12 V.
MOTOR_AVG_A, MOTOR_PEAK_A, MOTORS, DRIVING_FRACTION = 0.8, 3.0, 2, 0.6

p5_avg = 5.0 * sum(avg for _, avg, _ in rail_5v)
p5_peak = 5.0 * sum(peak for _, _, peak in rail_5v)
p_motors_avg = MOTORS * BATTERY_V * MOTOR_AVG_A * DRIVING_FRACTION

p_avg = p_motors_avg + p5_avg / REG_EFFICIENCY
i_peak = MOTORS * MOTOR_PEAK_A + (p5_peak / REG_EFFICIENCY) / BATTERY_V

energy_wh = BATTERY_V * BATTERY_AH * USABLE
print(f"5 V rail average: {p5_avg:.2f} W (draws {p5_avg / REG_EFFICIENCY:.2f} W from the battery)")
print(f"motors average:   {p_motors_avg:.2f} W")
print(f"total average:    {p_avg:.2f} W = {p_avg / BATTERY_V:.2f} A at {BATTERY_V:.0f} V")
print(f"worst-case peak:  {i_peak:.2f} A")
print(f"usable energy:    {energy_wh:.1f} Wh -> run time {energy_wh / p_avg:.2f} h")

Output:

5 V rail average: 9.75 W (draws 10.83 W from the battery)
motors average:   11.52 W
total average:    22.35 W = 1.86 A at 12 V
worst-case peak:  7.37 A
usable energy:    57.6 Wh -> run time 2.58 h

Reading the results:

  • The estimated run time is about 2.6 hours, or roughly 2 hours 35 minutes.
  • The computer and camera use almost as much energy as the motors. On many small robots, computing is a large share of the budget — a surprise to people who assume motors dominate.
  • The peak current of about 7.4 A is four times the average. The battery, wiring, switch and fuse must all be rated for it, even though the robot rarely draws it.

Making the estimate honest

A budget is only as good as its assumptions. Good practice is to:

  • State each assumption (driving 60% of the time, 80% usable energy) so others can check it.
  • Add margin. Real batteries deliver less energy when cold, old or discharged quickly. Many engineers plan for 20–30% less run time than the calculation gives.
  • Measure and update. Once a prototype exists, measure the actual current and correct the budget.

Recap

  • P = V × I; energy in Wh = power × hours; battery energy ≈ voltage × amp-hours.
  • Robots use several voltage rails; linear regulators waste the voltage difference as heat, switching regulators are more efficient.
  • Average power sets run time; peak current sets what the battery, wiring and fuses must survive.
  • An energy budget lists every load with average and peak values, states assumptions and includes margin.

Project

Paper or Python project: budget your own robot

Design, on paper, a power budget for a robot of your choice — for example a garden-watering robot or a small delivery robot.

  1. List every load with its rail voltage, average current, peak current and the fraction of time it is on. Use made-up but realistic numbers and label them as such.
  2. Choose a battery voltage and capacity. Calculate the average power, the peak current and the estimated run time, by hand or by adapting the Python program above.
  3. Change one design decision — a bigger battery, a more efficient regulator, or a computer that sleeps when idle — and recalculate. Which change helped most?

This is a calculation exercise only; do not connect any real batteries or motors.

Deliverables

  • A load list with average and peak currents and duty fractions
  • Calculated average power, peak current and run time
  • One design change and its effect on run time

Adult supervision requiredThis project is calculation only. If you later build anything, do so only under adult supervision, at low voltage, with a fuse near the battery and the manufacturer's charger, and never leave batteries charging unattended.

Knowledge check

Check your understanding

  1. 1. About how much energy does a 7.2 V, 5 Ah battery store?
  2. 2. A robot uses 18 W on average and has 54 Wh of usable energy. What is its estimated run time?
  3. 3. Every time its motors start, a robot's computer resets. Which quantity most likely needs attention?
  4. 4. A linear regulator supplies 0.2 A at 3.3 V from a 5 V input. Roughly how much power does it waste as heat?
  5. 5. Why do engineers usually plan to use only part of a battery's rated energy?