22  Energy-Aware Design Considerations

22.1 Learning Objectives

  • Distinguish between power and energy and explain why energy is the fundamental limiting resource for battery-powered IoT devices
  • Calculate average current draw and estimate battery life using duty cycling formulas
  • Select appropriate battery chemistries and energy harvesting technologies for specific deployment scenarios
  • Apply low-power design strategies (sleep modes, voltage scaling, peripheral power management) to extend device operational lifetime
  • Measure and profile energy consumption using shunt resistors and power profiling tools
In 60 Seconds

Energy-aware IoT design treats battery capacity as the most constrained resource, requiring every hardware and software decision — microcontroller choice, radio protocol, sensing frequency, sleep modes — to be evaluated by its energy cost, with the goal of extending device lifetime from days to months or years.

Key Concepts

  • Power vs Energy: Power (watts) is the rate of energy consumption; energy (joules or watt-hours) is the total amount consumed over time — battery life depends on total energy, not peak power
  • Average Current: The time-weighted mean current draw across all operating states; determines how long a battery will last
  • Duty Cycle: The fraction of total time a device spends in active mode; reducing duty cycle is the primary lever for extending battery life
  • Sleep Mode: A low-power state where the MCU and peripherals are partially or fully powered down to minimize current draw between active periods
  • Battery Capacity (mAh): The total charge a battery can deliver; battery life = capacity / average current
  • Self-Discharge: The rate at which a battery loses charge even when not connected to a load; important for long-deployment devices
  • Energy Harvesting: Generating power from ambient sources (solar, vibration, thermal) to supplement or replace battery power

Energy and power management determines how long your IoT device can operate between battery changes or charges. Think of packing for a camping trip with limited battery packs – every bit of power must be used wisely. Since many IoT sensors need to run for months or years unattended, power management is often the single most important engineering decision.

“Power and energy are NOT the same thing,” said Bella the Battery. “Power is how fast you use energy – like how fast water flows from a faucet. Energy is the TOTAL amount used – like how much water fills the bathtub. A device can use high power for a short time or low power for a long time and end up using the same total energy.”

Max the Microcontroller explained the key insight: “Every design decision affects battery life. The microcontroller you choose, the radio protocol, the sensing frequency, even the voltage level. A 3.3-volt system uses less power than a 5-volt system doing the same work. Small choices add up to big differences.”

Sammy the Sensor added, “The golden rule is: sleep as much as possible, wake only when needed, do your work fast, and go back to sleep. My idle current might be 1 microamp, but my active current is 10 milliamps – that is 10,000 times more! Every microsecond I stay awake unnecessarily shortens Bella’s life.” Lila the LED agreed, “Energy awareness is not an afterthought – it must be baked into every decision from the very beginning!”

22.2 Overview

Energy awareness is fundamental in IoT design. The difference between a device lasting weeks versus years depends entirely on careful attention to energy consumption at every level: component selection, circuit design, firmware implementation, and communication strategies.

This comprehensive guide is organized into focused chapters covering all aspects of energy-aware IoT design:

22.3 Chapter Guide

22.3.1 Foundations

  1. Introduction and Fundamentals
    • Why energy is the fundamental limiting resource
    • Power vs. energy concepts
    • The battery technology gap
    • Key design tradeoffs
  2. Energy Sources
    • Battery chemistries and selection
    • Primary vs. secondary batteries
    • Energy harvesting technologies overview
    • Capacity calculation and sizing

22.3.2 Analysis and Optimization

  1. Power Consumption Analysis
    • Power state analysis
    • Average current calculation
    • Radio power states
    • Protocol energy comparison
    • Power budget worked examples
  2. Energy Cost of Common Operations
    • Digital operation energy hierarchy
    • The million-to-one rule
    • Communication vs. computation tradeoffs
    • Algorithm and data type optimization
  3. Low-Power Design Strategies
    • Sleep mode implementation
    • Duty cycling strategies
    • Peripheral power management
    • Voltage and frequency scaling
    • Communication optimization

22.3.3 Measurement and Validation

  1. Energy Measurement and Profiling
    • Measurement tools and techniques
    • Shunt resistor method
    • Power profiler usage
    • Interpreting power profiles
    • Validating battery life predictions

22.3.4 Advanced Topics

  1. Energy Harvesting Design
    • Solar panel sizing
    • MPPT implementation
    • Supercapacitor selection
    • Thermoelectric and piezoelectric harvesting
    • Channel capacity limits

22.3.5 Practical Application

  1. Hands-On Lab: Power Monitoring
    • Wokwi simulation exercises
    • ESP32 deep sleep implementation
    • Wake-up source configuration
    • Optimization challenges
  2. Interactive Tools
    • Power budget calculator
    • Battery life estimator
    • Energy breakdown visualization
    • Auto-grading quiz
  3. Case Studies and Best Practices
    • Smart agriculture sensor optimization
    • Design phase best practices
    • Common pitfalls to avoid
    • Comprehensive review

22.4 Practical Examples

Scenario: Design cellular IoT water meter for 10-year battery life using 1× D-cell lithium (19,000 mAh @ 3.6V).

Requirements: Daily reading upload via NB-IoT

Component power:

  • MCU (STM32L4): 100 µA idle, 20 mA active
  • Flow sensor: Hall effect pulse counter, 50 µA continuous
  • NB-IoT modem: 200 mA TX/RX, 5 µA PSM (power saving mode)

Daily cycle:

1. Wake from PSM: 20 mA × 0.5s = 10 mAs
2. Read sensor (stored pulse count): 20 mA × 0.1s = 2 mAs
3. NB-IoT attach + TX: 200 mA × 5s = 1,000 mAs
4. Return to PSM: 1 mAs
Total active: 1,013 mAs = 0.28 mAh/day

Sleep (23.99 hours):
- MCU idle: 100 µA × 86,340s = 8,634 mAs
- Sensor: 50 µA × 86,400s = 4,320 mAs
- Modem PSM: 5 µA × 86,340s = 432 mAs
Total sleep: 13,386 mAs = 3.72 mAh/day

Daily total: 0.28 + 3.72 = 4.0 mAh/day
10-year budget: 19,000 ÷ 3,650 days = 5.2 mAh/day ✓ (30% margin)

Result: Design meets 10-year target with margin for temperature derating.

Why does sleep current dominate even with daily transmissions? The numbers reveal the counterintuitive truth:

Active vs Sleep contribution:

\[\text{Active energy: } 0.28\,\text{mAh/day} = 7\% \text{ of total}\] \[\text{Sleep energy: } 3.72\,\text{mAh/day} = 93\% \text{ of total}\]

Even though NB-IoT transmission uses 200mA (2,000× more than sleep), it only runs for 5 seconds per day. The MCU, sensor, and modem in low-power mode run for 86,400 seconds—17,280× longer.

\[\frac{\text{Sleep time}}{\text{Active time}} = \frac{86,400\text{s}}{5\text{s}} = 17,280\times\]

Lesson: For duty cycles below 1%, sleep current is the dominant factor. Reducing idle current from 100µA to 10µA would extend battery life from 10 years to 25 years—even without touching the radio!

22.4.1 Interactive Power Budget Calculator

Explore how different parameters affect battery life for duty-cycled IoT devices:

Application Primary Lithium LiPo Rechargeable Alkaline Criteria
10-year remote ✓ Best ✗ Self-discharge ✗ Leakage <1% yearly loss
Daily charging ✗ Expensive ✓ Best ✗ Not rechargeable >500 cycles
Cost-sensitive ✗ 5× cost △ Medium ✓ Best <$2 per unit
Cold weather ✓ -40°C rated △ -20°C limit ✗ -10°C limit Temperature range

Decision matrix: 10+ year remote → Primary lithium; 1-3 year replaceable → Alkaline; Rechargeable product → LiPo

Common Mistake: Ignoring Self-Discharge in Long-Term Deployments

The Mistake: Designing for 10-year life using LiPo battery (3% monthly self-discharge).

Impact: After 10 years, self-discharge alone: 100% - (0.97^120) = 97% capacity lost before any load!

Fix: Use primary lithium (<1% annual self-discharge) for multi-year deployments. LiPo only for <2 year life or rechargeable products.

22.5 Quick Reference

22.5.1 Target Specifications

Application Battery Life Target Max Avg Current
Field Sensor 5-10 years 50 µA
Smart Agriculture 2-5 years 100 µA
Wearable 1-7 days 5-20 mA
Smart Home 1-2 years 200 µA

22.5.2 Key Formulas

Average Current: \[I_{avg} = \frac{I_{active} \times T_{active} + I_{sleep} \times T_{sleep}}{T_{cycle}}\]

Battery Life: \[Life = \frac{Capacity \times Efficiency}{I_{avg}}\]

22.5.3 The Million-to-One Rule

Transmitting 1 byte over wireless costs approximately the same energy as 1 million 32-bit CPU operations. Always process locally when possible.

22.6 Knowledge Check

22.6.1 Interactive Protocol Comparison Calculator

Compare the energy impact of different wireless protocols for IoT sensing applications:

22.7 Concept Relationships

Energy-aware design integrates concepts from multiple engineering disciplines:

Electrical Engineering:

  • Power vs Energy: Instantaneous rate (watts) vs accumulated consumption (watt-hours)
  • Battery Electrochemistry: Li-ion vs LiFePO4 vs alkaline characteristics (cycle life, self-discharge, temperature tolerance)
  • Voltage Regulation: LDO quiescent current and efficiency impact on sleep mode power

Embedded Systems:

  • Processor Architecture: ARM Cortex-M low-power modes (sleep, deep sleep, standby)
  • Clock Management: Dynamic frequency scaling trades performance for power
  • Peripheral Power Domains: Independent power gating for unused components

Communication Theory:

  • Protocol Energy Cost: Transmission energy dominates (million-to-one rule: 1 byte TX = 1M CPU operations)
  • Duty Cycle Optimization: Periodic wake-up vs event-driven sampling
  • Network Protocols: BLE vs LoRa vs Wi-Fi energy comparison

System Design:

  • Requirement Decomposition: Battery life target → average current budget → component selection
  • Failure Mode Analysis: Identifying energy-draining edge cases (pull-ups, LEDs, debug interfaces)
  • Verification: Empirical measurement validates theoretical calculations

Environmental Science:

  • Temperature Effects: Battery capacity drops 35% at -20°C
  • Energy Harvesting: Solar irradiance varies seasonally (winter = 25-50% of summer)

Understanding energy-aware design requires thinking across layers: chemistry (batteries), hardware (sleep modes), firmware (duty cycling), protocol (transmission efficiency), and system (deployment environment).

22.8 See Also

Chapter Series Organization: This page is the overview and starting point for the energy-aware design chapter series. Explore individual topics:

Related Advanced Topics:

Hardware Design:

Communication:

System Design:

Industry Resources:

Common Pitfalls

Average power calculations can look excellent while peak current during transmission spikes exceed battery capability. Li-primary batteries have internal resistance that causes voltage drops under peak load. Verify that battery voltage under maximum load current remains above the microcontroller’s minimum operating voltage.

Battery capacity specifications assume room temperature (25°C). At −20°C, Li-SOCI2 capacity drops 15-30%, alkaline drops 50-70%. Outdoor IoT deployments in cold climates must derate battery capacity in sizing calculations to avoid premature device failure.

Datasheet sleep current values assume optimal configuration. Active clock sources, improperly disabled peripherals, and firmware bugs can cause actual sleep current to be 10-100x higher than specified. Always measure actual sleep current with a power monitor before finalizing battery sizing.

Energy calculations based on minimum message frequency miss peak duty cycles caused by exception conditions, retransmissions, and configuration mode. Design battery sizing for realistic worst-case duty cycles with 20-30% margin over estimated average.

22.9 What’s Next

If you want to… Read this
Start with energy fundamentals Introduction and Fundamentals
Learn hardware and software optimization techniques Hardware & Software Optimisation
Explore advanced context-aware energy management Context-Aware Energy Management
Practice with hands-on labs Hands-On Lab: Power Monitoring
Understand energy measurement tools Energy-Aware Measurement
Learn about energy sources and harvesting Energy Sources Overview