Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Look up keyword
Like this
4Activity
0 of .
Results for:
No results containing your search query
P. 1
How to extend the battery life of your microcontroller

How to extend the battery life of your microcontroller

Ratings:

5.0

(1)
|Views: 44 |Likes:
Published by api-3712130

More info:

Published by: api-3712130 on Oct 16, 2008
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less

03/18/2014

pdf

text

original

How to extend the battery life of your
microcontroller-based design
By Scott Pape
Courtesy ofEmbedded. co m
(07/26/2006 3:00 AM EDT)

Whether it is an electric toothbrush, shaver, cell phone, PDA, MP3 player or the remote
control for anything not within arm's reach, battery-powered devices are an everyday part
of life. As such, power management is a significant issue for embedded designers today.

The ubiquitous microcontroller offers designers a multitude of ways to manage the power
requirements in many applications. The different MCUs themselves offer a range of
current consumption and a variety of power saving features. However, power
management in an MCU-based design is more than just selecting the right
microcontroller.

It also means coming up with a development strategy that most effectively uses these
features. And at the system level, independent of the MCU that you have chosen, there
are also a number of strategies that can be employed to further extend the battery life of
your application.

Example Application: Wireless Bicycle Computer

To demonstrate effective power management, we will use a wireless bicycle computer as an example. This computer is composed of three modules, a control panel on the handle bars, a speed sensor on a wheel and a display on the rider's helmet.

The speed sensor tells the control panel how fast it is turning. The control panel
calculates information such as speed, distance covered, elapsed time and calories burned.
The control panel sends this to the display. Figure 1, below, shows a block diagram of a
bike computer control panel.

Figure 1. Block diagram for a wireless bicycle computer control panel,
demonstrating the enhanced power management features on today's MCUs.
Increased number of low power modes.

MCU's are moving into smaller geometries to reduce die size, which results in transistors that cannot tolerate direct application of 3 or more volts. So, voltage regulators are used to drop the voltage to the internal logic.

Unfortunately, these regulators add to the MCU's current draw. However, since power is
equal to voltage times current, a 1.8 volt to 3 volt system with a regulator may still be
lower power than a 5 volt system without one.

MCU's rely heavily on power management modes to keep the overall operating current
down while still supporting regulated power supplies and increased clock speeds. New
MCU's are providing multiple low power modes to address these needs and yet still
maintain system flexibility. Freescale's MC9S08GB60 MCU has four low power modes:
stop1, stop2, stop3 and wait.

In wait mode, power is reduced by turning off the CPU clock, but leaving the clocks
enabled to other MCU peripherals such as A-to-D converters, timers or serial
communication modules. This mode is useful for saving power when these peripherals
need to function, but the CPU has nothing to do until the peripheral completes its task.

In our example, wait mode could be used while the SPI is used to communicate with the
RF transceiver.
To reduce power consumption further, three stop modes can be used. Stop1, stop2, and
stop3 each provide different levels of operation that will reduce power consumption.
Stop3 provides the most functionality of the three. In stop3, the on-chip voltage regulator
is put into a power saving mode that still provides minimum regulation for retaining
RAM and I/O register contents. Several interrupt sources and the reset pin can wake the

MCU up from stop3. Stop3 is the only stop mode in which the low voltage inhibit (LVI) module can be enabled. It is also the only stop mode in which the crystal oscillator can remain enabled

In our example, stop3 can be used when the MCU is waiting between speed readings
from the speed sensor. The RTI function that runs in stop3 can be used to wake the MCU
in time for the next reading.

Stop2 provides slightly less functionality, but reduces power consumption further. In

stop2, the voltage regulator is powered down. However, the RAM contents are still
retained. The I/O registers are powered down in this mode and need to be reconfigured
upon wakeup from stop. In stop2, fewer interrupt sources are available to wake the MCU
up, but the RTI function is still available. Back to our example, stop2 can replace stop3 to
reduce power consumption slightly more. Since the RTI function and RAM both still
work in stop2, the time between speed readings can still be measured.

Stop1 is the lowest power mode of the MCU. It powers the voltage regulator down

completely along with all peripherals, the CPU, RAM and I/O. Only the reset or IRQ pins
can wake the MCU up. Stop1 is used when the MCU can be put into a powered down
state, but still needs to respond to an external stimulus such as the press of a button.

In the bike computer example, stop1 would be entered when the computer is powered
down. Powering down with stop1 mode puts the MCU in the lowest possible power mode
without actually removing power from the chip. Why not remove power from the chip?
Removing power requires a more expensive toggle switch to disable power to the chip.

Also, using a push button switch tied to an interrupt pin, allows the MCU to use the
switch for multiple purposes, depending on the current state of the system. So stop1 mode
is perfect for keeping the design simple, inexpensive and yet still consumes almost no
current.

Clock Management

Many designers equate low power to slow clock frequencies. However, depending on
what the MCU is doing and what low power modes are available on the MCU, running at
top speed can actually save power.

If the MCU has an efficient low power mode, then you will save the most power by
spending the most time in this mode. So if the CPU needs to execute code before
returning to sleep, running at the fastest possible speed to complete code execution and
return to low power mode can burn less current than running constantly at slow speeds.

Let's use our bike computer example. Assume the control panel gets a speed update once
every 1 second and it takes 16,000 bus cycles to compute the data to be displayed.
Running with a typical 32 kHz crystal and assuming a common divide-by-two bus clock,
we have a 16 kHz bus, in which case it takes 1 full second to complete the calculations.

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->