Professional Documents
Culture Documents
Overview
1. Understading Power Consumption 1.1 Dynamic Power 1.2 Static Power 2. Measuring Power Consumption 3. Performance vs Power 3.1 Wake-up Time 3.2 Clock Speeds and Power Efficiency 3.3 Instruction Set Architecture (ISA) 3.4 Properly Utilizing Peripherals 4. Low Power Software Design 5. Low Power Hardware Design 6. eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology 7. Microchip Next Generation Peripherals
When we consider power consumption in microcontrollers, we are actually considering two components:
Static Power Static power is the current consumed when the main clock is disabled. It is composed mainly of transistor leakage and the current used by voltage supervisors.
Dynamic Power Dynamic power is the current consumed by the switching of digital logic. It is mainly influenced by clock speed, although voltage and temperature also have an impact. For this reason, controlling dynamic power is largely a matter of controlling clock speed.
additional current consumption associated with the charging and discharging of the bus capacitance when the logic level changes.
Switching frequency The first point to consider is that voltage is the most significant factor in dynamic power consumption because the voltage term is squared. Reducing the system operating voltage will have a s i g n i f i c a n t i m p a c t o n p ow e r consump- tion. Load capacitance. It influences the fan out.
Control of C The embedded system designer has limited control over C, the internal load capacitance. The capacitance is a function of the internal MCU layout and design. It is up to the MCU manufacturer to limit the switching of load capacitance by utilizing proper low-power IC design techniques. Control of V Operating voltage is defined by the process technology used in the manufacture of the MCU. An embedded system designer can utilize his knowledge by selecting MCUs which are capable of operating at lower voltages. Control of f Frequency is typically the most variable of the factors contributing to dynamic power, and as such, is usually the component adjusted by embedded designers to actively control power consumption. The optimal operating frequency for a system is determined by a combination of factors: Communications or sampling speed requirements Processing performance Maximum peak current allowed
Agostino Polizzano agostino@polizzano.it
A critical trade-off becomes apparent when trying to optimize both dynamic and static power. Smaller process technologies have considerably lower dynamic power, but at the cost of much higher leakage current.
Agostino Polizzano agostino@polizzano.it
There are two values which are of primary concern: Average power consumption is the sum of the total energy consumed by the system in Dynamic and Static Power modes, divided by the average system loop time. Maximum power consumption is the worst-case power draw required by the system. It is important to determine maximum power consumption in order to properly design the system power supply.
In the event that there is no ammeter available that is capable of accurately measuring a very low-power application, an alternate method can be used, utilizing a capacitor. 1. Connect both switches to run the system and allow the capacitor to charge to VDD from the voltage source. 2. Disconnect the voltage source (and any voltage meters) and allow the application to run from the capacitor for a set amount of time. 3. Disconnect the capacitor from the application and connect a voltage meter to measure the remaining voltage on the capacitor. 4. Using Equation 2.
Using an ammeter to measure dynamic power under normal system operating conditions is usually not very useful. This is because the sampling speed of most ammeters is not fast enough to accurately measure the real-time power consumption of the system.
An effective way to measure dynamic power consumption is to use an oscilloscope to measure voltage across a shunt resistor. The oscilloscope will allow a designer to determine the changes in power consumption as the system steps through various states during operation, as well as measure the time spent in each state.
It is important to size the shunt resistor appropriately. It should be large enough to provide measurable resolution on the scope, but small enough not to cause a system brown-out in high-power states. Usually, a 10-100 ohm resistor is appropriate for dynamic power measurements.
Note that most high-accuracy and high-speed sources, such as crystals and Phase-Locked Loop (PLL) oscillators, have long start-up times.
Goals:
use a slow start-up source for a reduced consumption a fast wake-up time
Microchip solution:
Two-Speed Start-up feature
2
initially wakes up from the internal RC o s c i l l a t o r. T h e system runs from this oscillator until the primary clock source stabilizes.
3
Switch. Primar y clock source stabilizes.
1
Wake-up event
Therefore, when running at high speed from a battery-powered application, it is necessary to monitor VDD to determine if the battery voltage is dropping close to the minimum level required for fullspeed operation. If VDD drops below this voltage, it can cause code misexecution. Most MCUs provide a LowVoltage Detect (LVD) feature, which will interrupt the device if VDD drops close to this range. This will allow the firmware to reduce the operating frequency at low voltage, allowing the system to extend its lifetime.
To truly compare power consumption, it is necessary to consider how much actual work is performed per unit of energy consumed. Benchmarking is the only complete method to compare devices which take Instruction Set Architecture into account. It is also the most time-intensive method to compare devices. For a simple benchmark, there are some open source benchmark standards, which can be used to do get an initial comparison. By combining benchmark completion times with data sheet power consumption specifications, it is often possible to get a reasonable comparison of device power consumption.
low power
high speed
low speed
high power
DMA
A Direct Memory Access (DMA) controller is a powerful tool to reduce power consumption. The DMA improves performance by off-loading data transfer tasks from the CPU. Any features which can reduce CPU run time can help to drastically reduce power consumption, as clocking the CPU is the most powerintensive task in an MCU.
FIFO BUFFER
Many peripherals, capable of operating in Sleep, have built-in FIFO buffers which reduce power by enabling longer Sleep times. The FIFOs will store received or sampled data and will interrupt once the buffer is full. This allows the device to only wake up once to process the data. This consumes much less power than fully waking up a device to allow the CPU to handle each individual transfer.
Agostino Polizzano agostino@polizzano.it
Another example is the value of a RealTime Clock (RTC) versus using a timer module for wake-up. Keeping time with a timer module usually requires waking a device, once every second, to update the clock and check for an alarm condition. However, a Real-Time Clock and Calendar (RTCC) will allow the device to keep time and remain asleep until the alarm occurs, reducing power.
Push Buttons LEDs Connecting and Controlling I/O pins Unused Port Pins Analog Inputs
Leds
LEDs are a power consumption problem for similar reasons as buttons. They consume high power to run (2 mA-50 mA) and must be run for long periods of time in order to be useful to a user. The following are two of the main techniques for reducing LED power consumption: drive the LED at a lower duty cycle using a PWM; drive the LED at lower current levels by increasing the size of the current-limiting resistor. This is an especially useful technique with newer, high brightness and highefficiency LEDs.
Analog Inputs
Analog inputs have a very high impedance so they consume very little current. They will consume less current than a digital input if the applied voltage would normally be centered between VDD and VSS. Sometimes, it is appropriate and possible to configure digital inputs as analog inputs when the digital input must go to a low-power state.
[6] eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology
For PIC microcontrollers, the original low-power standard was referred to as nanoWatt Technology. Since its introduction in 2003, nanoWatt Technology has become the standard for all new PIC microcontrollers. The primary requirement to be considered a nanoWatt device was an overall power consumption in the nanoWatt range while in Sleep mode. Several new power-saving features were also introduced at the same time: Idle mode On-chip, high-speedoscillator (INTOSC) with PLL and programmable postscaler WDT with extended time-out interval Ultra Low-Power Wake-up (ULPWU) Low-power option for Timer1 and the secondary (32 kHz) oscillator Low-power, software-controllable BOR (Brown-out Reset) The most recent changes to nanoWatt Technology are collectively known as nanoWatt XLPTM Technology. To meet the nanoWatt XLP Technology specification, a PIC microcontroller is required to have typical current consumption of less than the following: 100 nA for Power-Down Current (IPD) 800 nA Watchdog Timer Current (IWDT) 800nA Real-Time Clock and Calendar (IRTCC)
Agostino Polizzano agostino@polizzano.it
[6] eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology
As more electronic applications require low power or battery power, energy conservation becomes paramount. Todays applications must consume little power, and in extreme cases, last for up to 15-20 years, while running from a single battery. Portable Medical Devices
The pace of innovation in the development of electronic medical devices is nothing short of revolutionary. Microchips products and experience have helped hundreds of the worlds top medical device companies take their ideas from future vision to market reality.
Thermostats
Demonstrate the flexibility of the PIC microcontroller platform for a range of thermostats from a low cost, segmented display to a fully featured graphical display with touch sensing.
Wireless
Microchip is enabling our PIC microcontroller customers with cost effective, easy to implement wireless solutions (transmitter, receiver, and transceiver solutions for IEEE 802.15.4/ZigBee, ISM Band Sub-GHz, and IEEE 802.11).
Smart Cards
VIEW Microchips smart card library supports PIC18 & PIC24 microcontrollers as well as providing the API necessary to communicate with the ISO7816-3/4 compliant smartcard.
[6] eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology
[6] eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology
[6] eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology
MSP430 16-bit Ultra-Low Power 16-Bit Microcontrollers by Texas Instruments vs eXtreme Low Power 16-bit Microcontrollers by Microchip Sleep Power Comparison
PIC MCUs with XLP has Lower Power than MSP430 MSP430 is 178% higher for Sleep with BOR(1) MSP430 is 33% higher for Sleep with RTC(2)
(1) (2)
Brown Out Reset (or BOR) is the ability for the microcontroller to reset itself if the supply voltage falls below a specified threshold. Real Time Clock (RTC)
[6] eXtreme Low Power PIC Microcontrollers with eXtreme Low Power Technology
MSP430 16-bit Ultra-Low Power 16-Bit Microcontrollers by Texas Instruments vs eXtreme Low Power 16-bit Microcontrollers by Microchip Sleep Power Comparison
Benefits
Increases on chip interconnection of peripherals and I/O Integrates hardware functions and saves board space Software control of Combinational/Sequential Logic Saves program code space and frees up CPU cycles
Benefits
Works with multiple peripherals Fewer components and less space Lower power Improved switching efficiencies
Example Applications
Switch Mode Power Supplies LED/Fluorescent Lighting Battery Charger Motor Drive
Advanced PWM capabilities for power supplies, motor and lighting control.
Key Features
Various clock sources: external, system clock, independent 64 MHz Various input sources: comparators, external pins Blanking control for transient filtering Single 16-bit PWM with up to 6 steerable outputs Complementary 16-bit PWM with up to 3 steerable output pairs Dead band with independent rise and fall control Polarity control/auto shutdown and restart Flexible PWM output modes: Push/pull, pulse skipping, 3-phase, fixed duty cycle, brushed DC with forward/reverse Output gating externally controlled activate/ deactivate
Example Applications
Power Supplies DC/DC Converters (Power Bricks) Power Factor Correction LCD Backlighting LED Lighting Automotive Head and Tail Lamps High Intensity Discharge (HID) Lighting Lamp Ballasts Signal Conditioning Motor Control Sensors Medical, Temperature, Pressure Battery Monitoring Advanced Battery Charging General Purpose Applications Requiring High Resolution PWM