55:036 embedded systems and systems...
TRANSCRIPT
Slide-1 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Embedded Systems and Software
Some Power Considerations
Slide-2 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Energy/Power Considerations
• Terms
– Cell, Battery
– Energy (Joule)
– Power (J/s or Watt)
– Ampere-hour (Ah)
– Deep-cycle
– MCU
– Sleep Modes
– ADC
– Data rate (BPS)
Slide-3 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Slide-4 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Radio-Serial Interface
Serial Interface Ultrasonic Sensor
Slide-5 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Creek or Small River
Slide-6 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Attach Distance Sensor
Slide-7 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Wake up, Measure Distance to Surface
Slide-8 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Wake up, Measure Distance to Surface
Slide-9 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
An Embedded System
Relay Data Back to Servers on Internet
To UI Via Cell Modem
Slide-10 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Simplified System Diagram
Slide-11 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Electronics
Ultrasonic Sensor
Cell Modem
(Note Green Dot)
“Electronics” Solar Charge Controller
Battery
Cell
Antenna
GPS
Antenna Serial-Radio
Interface Antenna
LED
Serial-Interface
Connector
Slide-12 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Electronics
LP3500 Development PCB
GPS SD Card External
Memory
Glue Board
Cell Modem
Slide-13 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Where Does The Power Go?
Typically contains it
own MCU + firmware
May be part of
microcontroller
Slide-14 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Principles
fVCP 2
Power dissipated Capacitance Voltage
Switching
frequency Number of
active gates
The following is a simple model for the power
dissipated by a CMOS-based system
(turn off unused systems)
(lower clock)
(Lower voltage) (Use simpler uC)
Slide-15 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Digital Switching Levels
Time
Reducing power consumption is the main reason for push
towards lower voltage levels
Slide-16 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Microcontroller Unit (MCU)
• Intel’s StrongARM, Atmel AVR, PIC, …
• Several low power modes
– Active, idle, nap, shutdown, sleep modes
Various MCU subsystems are turned off
Different clock speeds
– For some MCUs, in deep sleep modes, the power
consumption can almost be negligible
– Takes longer to wake from a deep sleep than just a nap
– Wakeup time also takes power
– Wakeup impacts processing
Slide-17 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Radio
• Radio typically contains an embedded controller that provides many functions – Uses RSSI to adjust transmit power
– Error detection and correction in hardware/firmware
• Several modes – Receive only, transmit + receive, idle, etc.
• In general, transmit requires most power
• Carefully consider radio spec and modes
• Mode change can consume a lot of power – May be better to shutdown completely rather than go
into idle mode
Slide-18 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Sensors
Passive & low power (~mW and smaller) – Soil moisture, temperature, light, humidity
• Active & high power – Anemometers, disdrometers, cameras
• Many sensors are inherently analog, but some sensors have digital interfaces (provided by embedded controllers)
• Conditioning/wakeup times need to be considered
• Analog-Digital Converters (ADC) – Can be a major power consumer
– More bits and high conversion rate requires more power
– Don’t over-specify
Slide-19 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Batteries
• Uses chemical reaction to provide electrical energy
• Battery vs Cell
• Batteries are often the most bulky part of a device
• Capacity measured in Ampere-hours (Ah) or mAh
• Note that the capacity does not consider voltage…
• The capacity is the nominal number of hours it can supply a given current. Normally specified at given load conditions and temperature. For example, 100 mA constant current discharge, 70% of open circuit voltage and 20 oC.
• Battery Chemistries: Alkaline, Lead-Acid, Li-ion, NiMH, etc. Each chemistry has its own characteristics
Slide-20 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Constant Current Discharge Curve
0 200 400 600 800 1000 1200 1400
0.25
0.5
0.75
1
1.25
1.5Constant Current Discharge (100 mA)
Vo
lta
ge
(V
)
Discharge Time (min)
Duracell AA
Energizer NH15-2500
Eveready Gold
Kodak AA
Panasonic HHR-160AAB
RadioShack Enercell
Rayovac Maximum Plus
Slide-21 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Battery Capacity
• AA Size batteries – Few hundred mAh (Alkaline) to ~ 3,000 mAh (Li-ion)
• Factors – Previous number of discharges. Capacity decreases as the cycle
number increases.
– Temperature. Overall, capacity decreases with decreasing temperature, but over some temperature ranges, capacity my increases
– Load. Higher loads reduce apparent capacity
Slide-22 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Battery Capacity
0 200 400 600 800 1000 1200
0.2
0.4
0.6
0.8
1
1.2
1.4
1.6 Rayovac Maximum Plus ( Alkaline, AA)
Vo
lta
ge
(V
)
0 200 400 600 800 1000 1200
50
100
150
200
250
300
350
400
Cu
rrent (m
A)
Discharge Time (min)
70%
Capacity is Area
Slide-23 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Capacity Dependence on Load
• Peukert’s Law is often used as a model:
• t is discharge time, I is discharge current, and n
is Peukert’s number that depends on battery
chemistry and battery history. Values for n range
between 1.1 – 1.2. C is the capacity removed
from the battery.
• Empirical formula
• Dimensionally inconsistent, and often interpreted
and used incorrectly.
tIC n
Slide-24 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Capacity Dependence on Load
• Better formulation of Peukert’s law:
• Here C0 is the capacity measured at I0, and CI is the capacity at a load I.
• The state of charge (SOC) of a battery is defined as:
Where CI is the capacity at a load I
1
0
0
n
I
I
I
C
C
IC
tI 1SOC
Slide-25 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Example
• An NiMH cell has Peukert’ number n = 1.1 and has a
capacity of 2,500 mAh measured at 50 mA and 20 oC. (a)
What is the cell’s capacity at a load current of 300 mA?
(b) What is the SOC after 2 hours at a load of 300 mA?
mAh 090,2836.0500,2
836.0300
5011.11
0
0
I
n
I
C
I
I
C
C
%7171.0090,2
230011SOC
IC
tI
Slide-26 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Battery Capacity
50 100 150 200 250 300 350 400 4501500
2000
2500
3000
Load Current (mA)
Ca
pa
city (
mA
h)
Capacity vs Constant Load Current
EA
EB
ED
EE
EF
EG
EH
EI
EJ
EX
Linear fit (no Peukert)
Slide-27 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Effects of Temperature
• Temperature affects rate of chemical reactions and influences battery capacity
• Lower temperatures => lower (apparent capacity)
• Broadly speaking, temperature effects are reversible – Some manufacturers specify “% Service vs.
Temperature” rather than “Capacity vs. Temperature”
• At very high and very low temperatures damage to battery occur
• Temperatures affect self-discharge & shelf life
Slide-28 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Effects of Temperature
Se
rvic
e (
%)
Cap
acity (
%)
Temperature (oC) Storage Time (days)
Se
rvic
e (
%)
Cap
acity (
%)
Temperature (oC) Storage Time (years)
Slide-29 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Modeling Temperature Effects
• Simple linear model for “%Service”
• Here S(T) is “% Service”, T0 is where Service = 100%, and
is the temperature coefficient of the “%Service”. For
batteries that exhibit a plateau, this equation would apply
to the relevant part of the plot.
• Simple linear model for self discharge
)(1100)( 0TTTS
TdCdTC 1),( 0
Where C(T,d) is the capacity of the battery after d
days of storage at temperature T, and has units
day-1 oC-1
Slide-30 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
0 200 400 600 800 1000 1200 1400
0.25
0.5
0.75
1
1.25
1.5Constant Current Discharge (100 mA)
Vo
lta
ge
(V
)
Discharge Time (min)
Duracell AA
Energizer NH15-2500
Eveready Gold
Kodak AA
Panasonic HHR-160AAB
RadioShack Enercell
Rayovac Maximum Plus
Estimating Battery Capacity
May be possible to use curve to gauge
battery state. Must be under load conditions.
May not be possible to use
curve to gauge battery state.
Slide-31 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Question: what type of diodes should D1, D2, be, and why?
Answer: Schottky diodes, because they have lower turn-on voltages than Si
diodes. Thus, these diodes dissipate less power.
In normal operation, the 5 V linear regulator provides clean 5 V. D1 drops VD(on) .
This is greater than (3 V + VD(on) ), so D2 is reverse-biased and open.
Without main power, D2 is forward biased turn on, and powers the controller.
Power Supplies
Slide-32 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Coin & Button Cells
• Capacities: 50–300 mAh
• Designed for 3–200 A or few mA pulsed load
• Enough to power CMOS
• Used for RAM backup
• WSN: Power RTC
• Li chemistry typical
– => single cell
– => very long service
Slide-33 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Power Supplies
Linear Three-Terminal Regulator
Quiescent current for LM78xx regulators are large,
and can waste lots of energy not suitable for
battery-operated equipment.
Slide-34 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Power Supplies
MAX604 Linear Regulator
Quiescent current for MAX604 a few micro-amps, thus
much more suitable for battery-operated equipment.
Slide-35 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
DC/DC Converter
Simple Buck Converter
Feedback provides regulation
Slide-36 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Power Supplies
MAX724 DC/DC switching Regulator
Very wide input range, efficient conversion to output
voltage
Note that switching regulators can step up voltages
Slide-37 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Battery Models
• Motivation – Understand battery behavior
– Simulate battery behaviors
– Predict battery lifetime. Think about the battery-icon on your cell phone
• Physical models
• Abstract models – Electrical circuit models
– Discrete time models
– Stochastic models
– Mixed models
• Empirical Models
Slide-38 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Physical Battery Models
• Consists of differential equations that describe electrochemical processes in detail:
• Most accurate, but some can require up to 50 parameters, thus hard to configure model
• Not feasible to embed in an embedded system…
Write sets of differential equations that
describe reaction and diffusion processes
(at both electrodes). Incorporate effects
of temperature on electrolyte, ion mobility,
passive film forming at electrodes etc.
Solve equations
Slide-39 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Empirical Battery Models
• These models attempt to capture/describe behaviors of interest using simple equations
• Examples include Peukert’s law, self-discharge, etc:
• Simplest to configure and use
• Generally not very accurate (Peuket’s law)
• Model parameters are chemistry- and battery specific. For example, Peukert’s number for an alkaline AA may be different for a same-brand AAA battery.
• However, a well designed empirical model based on good experimental data for a specific battery model can be very accurate, and simple to embed
1
0
0
n
I
I
I
C
C TdCdTC 1),( 0
Slide-40 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Coulomb Counter/Battery Fuel Gauge ICs
Fuel gauge; Q = I×t Coulombs = > Coulomb counter
Example 15 bit (1.6 V / 78A) measurement Unique ID DS2740
Li-
Ion
ba
tte
ry
Slide-41 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Smart Batteries
Transient Voltage Suppression
Slide-42 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Smart Battery
Smartbattery monitor
Slide-43 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger
Question 1. (10 points) Consider a battery-operated consumer electronics device
that uses an embedded microcontroller that will accept a 2.7–5.5 V power. The device
can also be powered from a power supply that plugs into a mains outlet. Consumers’
expectation is that the switchover between battery- and mains power is transparent.
That is, the instant a user inserts the power supply connector, the device switches to
the power supply, and the instant the user unplugs the device, it switched to battery
power.
Draw a block diagram/schematic that shows how to implement this functionality using
diode(s), linear regulator(s), battery, etc. Explain how the circuit works. Provide as
much details as you can. For example, specify the type of diodes, indicate voltages on
the diagram, include critical capacitors, and so on. You can assume that unregulated
9 V dc power is available.
Question 2. (10 points) List (1 point) and the briefly explain (1 point) five design
considerations that one can employ to reduce the power consumption in an AVR-
based embedded system.
Sample Exam Questions
Slide-44 Embedded Systems and Software, ECE:3360. The University of Iowa, 2016 A. Kruger