13 Power WDT 2010


Silicon Labs C8051F50x
Supply Voltage 1.8 to 5.25 V
typical operating current: 18 mA @ 50 MHz; 20 µA @ 32 kHz
typical stop mode current: 3 µA
Digital Peripherals
Podstawy techniki
- All I/O Ports 5 V tolerant with high sink
mikroprocesorowej
current
ETEW006
- CAN 2.0 Controller  no crystal required
- LIN 2.0 Controller (Master and Slave
capable); no crystal required
Redukcja mocy
- Hardware enhanced UART, SMBus"!, and
EMC
enhanced SPI"! serial ports
Niezawodność działania programów
Clock Sources
- Internal 24 MHz with Ä…0.5% accuracy for CAN and master LIN operation
- External oscillator: Crystal, RC, C, or clock (1 or 2 pin modes)
- switch between clock sources on-the-fly; useful in power saving modes
Andrzej Stępień
Temperature Range:  40 to +125 °C
Katedra Metrologii Elektronicznej i Fotonicznej
CMOS Power Consumption and Cpd Calculation.
Texas Instruments, SCAA035B, June 1997
TI MSP430F2xxx / MSP430F54xx
Power Consumption
Low Supply Voltage Range 1.8 V to 3.6 V
Ultralow Power Consumption (MSP430F54xx):
- Active Mode (AM): 165 µA/MHz at 8 MHz
- Standby Mode (LPM3 RTC Mode): 2.60 µA
static (Ps)  in the datasheet:
- Off Mode (LPM4 RAM Retention): 1.69 µA
" ICC
- Shutdown Mode (LPM5): 0.1 µA
" "ICC
"
"
"
Five Power-Saving Modes
Ultrafast Wake-Up From Standby Mode in Less Than 1 µs (MSP430F2xxx)
dynamic power consumption (Pd)  usually forms the bulk
Basic Clock Module Configurations (MSP430F2xxx):
of power consumption:
- Internal Frequencies up to 16 MHz With Four
" transient power consumption (Pt)
Calibrated Frequencies to Ä…1%
" capacitive load power consumption (PL)
- Internal Very Low Power LF Oscillator
How to
- 32-kHz Crystal power an
MCU
- External Digital Clock Source
Static Power Consumption Dynamic Power Consumption
transient power consumption (Pt):
PT = Cpd " VCC2 " fI" NSW
ICC  supply current where: Cpd = dynamic power-dissipation capacitance
PS = VCC " ICC where: VCC = supply voltage VCC = supply voltage
ICC = current into a device fI = input signal frequency
(sum of leakage currents) NSW = number of bits switching
"ICC  extra supply current for every input that is at a voltage other
"
"
"
capacitive load power consumption (PL):
than 0 or 5V (when the input levels are not driven all the way to
the rail, causing the input transistors to not switch off completely) PL= CL " VCC2 " fO " NSW (CL is the load per output)
where: VCC = supply voltage
fO = output signal frequency
CL = external (load) capacitance
NSW = total number of outputs switching
1
Power
Power Consumption With a Single
Consumption
Output Switching for TI s  245
in Golf (das Auto)
Matt Ruff (Freescale Semiconductor)
Reducing power consumption in
batterypowered applications.
EDN, 2007, may 24, p. 81
Figure 4 Reducing the
average current draw
Frequency [MHz]
has different impacts
Figure 8. Power Consumption With a Single Output Switching for TI s  245 on battery life.
Steve Kennelly: Reducing Power Consumption in Embedded Medical
Electronics. Medical Electronics Manufacturing, Spring 2007
Power Reduction Methods
Medical Electronics
in MCU
Small device packages, reduced power consumption Some MCU families now commercially available provide special features for
power management; these generally involve controlling power consumption
Advanced semiconductors that integrate more features on a single by peripherals, letting the MCU sleep periodically, or manipulating
device have enabled designers to miniaturize medical devices and to oscillator start-up
extend device lifetimes by lowering power consumption
Controlling Power to Peripherals  a cardinal principle of power
Batteries are the principal power source in many low-power applications management in portable embedded systems is to enable the MCU to control
the power used by both internal and external peripherals; for example, a
Batteries that are suitable for high-current applications have lower brownout-reset feature is not needed in battery-powered applications. A
capacity or greater weight than a similarly sized high-internal-resistance designer thus can save power by disabling it
battery
MCU Sleep Modes  put the MCU to sleep occasionally, at times when the
MCU to be able to handle a variety of low-powered designs, it is important that system's demand for the controller's resources is low; then, to perform useful
it operate with a wide range of power supplies: for instance, when a device work, the sleeping MCU is awakened, either through an interrupt or when a set
uses alkaline batteries, 1.8-V operation is desirable because the end voltage period on a watchdog timer has expired  longer the MCU can be allowed to
on each cell is 0.9 V and the application typically employs two cells sleep, the lower the average power consumed by the application will be
Power Reduction Methods Power Reduction Methods
Oscillators Bidirectional I/O pins
Start-up event occurs while the MCU is idle (that is, not executing any code): designers should be careful about the signals applied to these pins so
that the amount of power consumed can be minimized
- during the start-up period, as the oscillator stabilizes, the MCU is not doing
any work, yet it continues to consume power
- oscillator start-up time usually is not mentioned in the MCU's data if a port pin is unused, the designer can leave it unconnected but
sheet, because its duration will vary depending on the crystal, loading configured as an output pin driving to either state, high or low, or, it can
capacitors, system environment, oscillator mode, and so on be configured as an input with an external resistor pulling it to VDD (the
supply voltage) or VSS (the ground)
Use a two-speed oscillator start-up:
when the port pin is configured as an input, only the pin input leakage
- MCU immediately starts to execute code from a fast-starting secondary
current will be drawn through it  current flow would be the same if the
oscillator, such as a RC oscillator
pin were connected directly to VDD or VSS
- when the primary oscillator is ready, it is switched into the circuit to replace
the secondary oscillator
in this way, the pin can be used later, for either input or output, without
- such a design is critical for applications in which a device cycles from sleep
extensive hardware changes
to waking and back frequently
2
CC
I
[mA]
Matt Ruff (Freescale Semiconductor): Reducing power consumption
in batterypowered applications. EDN, 2007, may 24, p. 82
RUN MODE
HIGH-SPEED SERVICING IS REQUIRED:
Power
Power Reduction Methods
INCREASE BUS SPEED TO 20 MHz WITH
INTERNAL CLOCK GENERATOR
Consumption
Peripherals COMPLETE TASK, THEN GO BACK TO
STOP 2 WITH AVERAGE WAIT TIME
RUN MODE
EXTERNAL EVENT TRIGGERS RUN MODE,
Fig. 2 The power-
FAST START-UP WITH 4-MHz-BUS SELF-CLOCK MODE
consumption profile
for stop and run
modes includes a
COMPARATIVE
periodic wake-up
POWER
CONSUMP
STOP 1
DEVICE TIMES OUT, ENTER
STANDBY POWERDOWN,
STOP 1
TYPICALLY 20 nA AT 2V
STANDBY POWERDOWN,
TYPICALLY, 20 nA AT 2V
Figure 1. The I/O pins of an MCU can be used to power the
STOP 2 WITH AVERAGE WAIT TIME/ RUN MODE
REAL-TIME CLOCK ENABLED AVERAGE WAIT TIME/RTC TRIGGERS RUN MODE
EEPROM and the sensor in this data-recorder application
INTERNAL 2-kHz WAKE-UP CHECK WHETHER HIGH-SPEED SERVICE IS
OSCILLATOR ON NECESSARY;
RAM AND I/O CONTENTS POWERED, IF NOT, GO BACK TO STOP 2 WITH AVERAGE WAIT
TYPICALLY, 700 nA AT 2V TIME ENABLED
A. M. Holberg, A. Saetre: Innovative Techniques for Extremely Low Power Consumption
with 8-bit Microcontrollers. White Paper, Atmel Co. 2006
Active versus Sleep Mode (AVR MCU) (1/2) Active versus Sleep Mode (AVR MCU) (2/2)
Arne Martin Holberg, Asmund Saetre: Innovative Techniques for Extremely Low
Power Consumption with 8-bit Microcontrollers. White Paper, Atmel Co. 2006
Current
consumption
In many applications, the processor does not run continuously and peripherals
may be idle much of the time. The overall power consumption can be lowered by
10% Duty Cycle
taking advantage of various  sleep modes available on virtually all processors. The
Active ICC
most common sleep modes are Power Down (PWD), Power Save (PS) and Idle.
In Power Down mode everything is shut down, including the clock source. In Power
Save mode everything is turned off except a 32 kHz clock running from a crystal
Average current
to keep track of time. Idle mode is a shallow sleep mode where only parts of the
Sleep ICC
device are shut down but the main parts of the microcontroller are running.
The advantage of having multiple sleep modes is the flexibility it provides to shut down
any part of the microcontroller that is not absolutely necessary to the function at hand.
Time
The amount of power that can be saved depends on the mode being using. For
example with a 1.8V supply voltage operating at 1 MHz and 25ºC, Atmel s
Figure 1: Power budget
ATmega165P AVR controller consumes 340 µA in Active mode, 150 µA in Idle
µ µ
µ µ
µ µ
mode, 0.65 µ µ
µA in Power Save mode and a scant 0.1 µA in Power Down mode.
µ µ
µ µ
Power Saving Modes
Low-Power Applications
Active Mode  CPU is Active and all Modules (Peripherals) are Active
Principles
Slow Down Mode  slows down all parts of the controller, the CPU and all
Most important factor for reducing power consumption is using the clock
peripherals; Slowing down the frequency significantly reduces power
system with both a real-time clock function and all interrupts active
consumption. The slow down mode can be combined with the idle mode
(MSP430Xxxx: 32-kHz watch crystal is used for the ACLK and the CPU is
Idle Mode  CPU is gated off from the oscillator, all peripherals are still
clocked from the DCO (normally off) which has a 6-µs wake-up)
provided with the clock and are able to work; Idle Mode is entered by software
and can be left by an interrupt or reset
Use interrupts to wake the processor and control program flow
Atmel: Idle mode is a shallow sleep mode where only parts of the device are
Peripherals should be switched on only when needed
shut down but the main parts of the microcontroller are running
Use low-power integrated peripheral modules in place of software driven
Wait Mode  CPU operation is stopped, oscillators remains active (Renesas)
functions (MSP320Xxxx: for example Timer_A and Timer_B can automatically
Standby Mode  Low-power Mode 3 in MSP430 (LPM3), disabled: CPU,
generate PWM and capture external timing, with no CPU resources)
MCLK, SMCLK, DCO s dc-generator is disabled; ACLK remains active
Calculated branching and fast table look-ups should be used in place of
Power Down Mode / Stop Mode / Halt Mode  (Hardware or Software)
flag polling and long software calculations operation of the MCU is completely stopped and the oscillator is turned off;
this mode is used to save the contents of the internal RAM with a very low
Avoid frequent subroutine and function calls due to overhead
standby current
For longer software routines, single-cycle CPU registers should be used DVS  Dynamic Voltage Scaling
3
COP8CBR MSP430 Low Power Mode (Texas Instruments)
National Semiconductor
HS Osc on RST/NMI
Vcc On
LS Osc off
Reset Active
T0 clked by HS Osc
WDT Active POR
HS Osc off
Halt High
Time Expired, Overflow
WDTIFG=0
Reset
Speed
RST/NMI is Reset Pin
WDTIFG=1 PUC
Mode
WDT is Active
LS Osc on Idle
WDT Active All On RST/NMI
Security Key Violation NMI Active
Active Mode
32 kHz
HS Osc off
HS Osc off CPU is Active All Off
Low Power Mode 0
Halt Halt
LS Osc on
Various Modules are Active
Low Power Mode 4
Low Dual LS Osc on
CPU Off, MCLK Off, SMCLK On
CPU Off, MCLK Off, SMCLK Off
DCO On, DC Gen On
Speed Clock
Icc=225mA (@Vcc=2,2V)
DCO Off, DC Gen Off
ACLK On
Mode Mode
HS Osc off HS Osc off ACLK Off
Idle Idle
Low Power Mode 1
LS Osc on LS Osc on Icc=0,1mA
Low Power Mode 3
HS Osc off HS Osc on
CPU Off, MCLK Off, SMCLK On
CPU Off, MCLK Off, SMCLK Off @Vcc=2,2V
LS Osc on LS Osc on
DCO Off, DC Gen On
DCO Off, DC Gen Off
T0 clked by LS Osc T0 clked by LS Osc
ACLK On
Low Power Mode 2
ACLK On
Icc=65mA CPU Off, MCLK Off, SMCLK Off Icc=1mA
DCO Off, DC Gen On
The low speed oscillator is left on in HALT mode, because the low speed @Vcc=2,2V @Vcc=2,2V
ACLK On
oscillator draws very little operating current.
Icc=11mA (@Vcc=2,2V)
Cortex-M3
P All clocks including IRC are stopped.
???
Internal voltage is turned off
Complete system state is lost, only
special registers in the RTC domain are
One question system designers may ask themselves is:
preserved
Wake up via reset, external pin, or RTC
 Why do I need one of these things anyway ?
Alarm
CPU execution is suspended There are 3 situations that you must consider when answer-ing this
Peripherals continue running question:
" what would happen to the microcontroller (or other devices in the
Main oscillator and all internal clocks except the IRC
system) if there was noise on the supply voltage as it powers up ?
are stopped
Flash memory is in standby, ready for immediate use
" what would happen if there is a glitch on the power supply while the
system is running ?
Same as Deep-Sleep mode except
Flash and IRC are shut down
" what does the microcontroller do when the system power is turned
off ?
UM10120. LPC2131/2/4/6/8 User manual.
Philips Semiconductors, Rev. 02  25 July 2006
Brown-Out Detection
Glitch
Glitch
VIT+= 4,59V
in power LPC213x
Vhys
in
supply VIT-= 4,55V
power
VCC=5V BOD has 2-stage monitoring of the voltage on the VDD pins:
Low end of operating range
VIT
Mic roco ntroller 'los es c o ntro l' here
supply tGmin
" if VDD voltage falls below 2.9 V, the Brown-Out Detector (BOD)
Danger
>200ns Other components
Zone
in syste m asserts an interrupt signal to the Vectored Interrupt Controller
~1,5V
may work down to here
~0,7 .. 1.1V (must be enabled for interrupt)
t
" if VDD voltage falls below 2.6 V, Reset prevents alteration of the
Manual
Flash as operation of the various elements of the chip
Res et
" both the 2.9 V and 2.6 V thresholds include some hysteresis
BOD circuit maintains this reset down below 1 V, at which point the
AN686, Microchip
RESET
Power-On Reset circuitry maintains the overall Reset
S LVA056A,
td td td 200ms Texas Ins truments
BOD wakes up MCU and continues operation, bring LPC213x out of
Power-Down mode
Output Undefined
Output Undefined
4
DVS Power Management Mode (PMM) (1/3)
Dynamic Voltage Scaling:
External Interrupt or RESET
" dynamiczne przełączanie napięć zasilających w układach, które nie
PMM1 Idle Mode
pracują z pełną mocą (np. odtwarzacz MP3, internetowe audio, kamera
XTAL/64 (only CPU OFF)
cyfrowa itp.)
Active Mode
" obniżenie napięcia zasilania rdzenia (UCC), zmniejszenie częstotliwości
software hardware
Cristal Oscillator XTAL/4
taktującej (fCLK) w mikroprocesorach, procesorach sygnałowych (DSP)
/Ring Oscillator
Stop Mode
PMM2
" pobór energii proporcjonalny do (UCC)2 " FCLK, zmiana częstotliwości
XTAL OFF
XTAL/1024
taktujÄ…cej
(All OFF)
" wydłużenie czasu życia baterii o ok. 15-25% przy oszczędnym
gospodarowaniu energiÄ…
Stop Mode
" właściwe zaprojektowanie struktury mikroprocesora, DSP sterującej
All OFF +
stabilizatorem napięcia
Kevin Self - Microcontrollers Applications
Cristal Ampl. OFF
Engineer, Dallas Semiconductor Corporation
ICC Current Exit from Stop Mode
4 .. 10 ms
µC operating µC operating
Icc [mA] Cristal
Type of mode:
Oscillator
35
(active mode
XTAL/4
Power
full speed)
DS80C320
30
(4 clocks - performance 2,5x)
µC enters Ext. Interrupt Clock µC enters
25
Stop Mode Clock starts stabile Stop Mode
20
µC operating
Cristal
15 µC operating
(backward software Oscillator
compatibility)
Idle
10 RC
(PMM1 with NOP)
XTAL/64
Oscillator
5
(PMM2 with NOP)
XTAL/1024
Power Power saved
(1 mA)
Stop Mode
1 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30
µC enters Ext. Interrupt µC enters
Frequency [MHz] Stop Mode Clock starts Stop Mode
Power .vs. Clock Frequency Wewnętrzne generatory MSP430x1xx
LFXT1CLK - Low/high-frequency oscillator:
" low-frequency 32,768-Hz watch crystals
" standard crystals, resonators
" external clock in the 450k .. 8MHz range
Burst Mode Operation
Energy consumed vs. processor speed for a 500 machine cycle task,
active mode
XT2CLK - Optional high-frequency oscillator:
Clock Machine Total Current
" standard crystals
Frequency Cycle Time ICC -Time
" resonators
Period Product
" external clock in the 450k .. 8MHz range
DCOCLK - Internal digitally controlled
10 MHz 400 ns 200 ms 12,41 mA 248 mAs
oscillator (DCO) with RC-type characteristics.
30 MHz 133 ns 66,5 ms 34,66 mA 230 mAs ( 6%)
5
HC 49S
Rezonator kwarcowy (1/2) Rezonator kwarcowy (2/3)
HC 49S
HC 49S/SMD
HC 49U
TF206 /SMD
B. Gniewińska, C. Klimek: Rezonatory i generatory kwarcowe. WKiA, Warszawa 1980
MCU
Układ zastępczy
Częstotliwość rezonansu
Reaktancja
rezonatora kwarcowego
równoległego:
bez obudowy i mocowania
XL
C1
fa = fS 1 +C + C0
L1 C1 R1
"
L
f
fS fa
CX
gdzie:
XC
CX1 CX2
CX1 CX2
CL = CX +
C0
CX1 + CX2
L1 C1 R1
Częstotliwość rezonansu Częstotliwość rezonansu
szeregowego: równoległego:
fa - fS
1 A B
C1
1 1
1 fS < 0,01 .. 0,5 %
fS =
fa = + = fS 1 +
"L1C1 L1C0 "
2  " L1C1 C0
C0
2 
Startup Time Crystal Oscillator Start-Up
CX1,2 = 30 pF
Clay Turner: Use of the TMS320C5x Internal Oscillator With External Crystals or TOM WILLIAMSON: Oscillators for
VCC
Ceramic Resonators. SPRA054, October 1995, Texas Instruments Microcontrollers
APPLICATION NOTE AP-155, June 1983, Intel Corp.
 Startup time is dependent on the external components used, but
generally requires at last 100 ms after power-up for the oscillator to
TS, ms
stabilize. For this reason, a reset delay of 150-200 ms is recommended
X2
following power-up.
COP8CBR9/COP8CCR9/COP8CDR9. 8-Bit CMOS Flash Microcontroller
CX1,2 = 50 pF
with 32k Memory, Virtual EEPROM, 10-Bit A/D and Brownout.
DS101374, April 2002, National Semiconductor
VCC
CKI Frequency Startup Time
10 MHz 1  10 ms
3.33 MHz 3  10 ms
1 MHz 3  20 ms
X2
455 kHz 10  30 ms
Oscillator Start-Up (4.608 MHz Crystal
32 kHz 2  5 sec (low speed oscillator) from Standard Crystal Corp.)
Parametry rezonatorów kwarcowych
Crystal Specifications
Nominal frequency range f 32.768 kHz
Temperature storage TSTG -55°C to +125°C
Parameter Symbol Min Typ Max Units
Crystal Considerations with
range operating TOPR - 40°C to +85°C
Dallas Real Time Clocks. APP58, F0 32,768 kHz
Nominal Frequency
Maximum drive level GL 1,0 µWMAX
Dallas Semiconductor, 1995
Load Capacitance CL 6 pF
Soldering condition TSOL Twice at under 260°C within 10 s
o
T0
Temperature Turnover Point 20 25 30 C
or under 230°C within 3 min.
0,042 ppm/ o C
Parabolic Curvature Constant k
Frequency tolerance (standard) "f/f Ä…20ppm or Ä…50ppm
Quality Factor Q 40.000 70.000
(Ta=25°C, DL=0.1µW)
Daiwa DS-26S Crystal Series Resistance R1 45 k&!
Peak temperature (frequency) ¸T 25°C Ä…5°C
Specifications Shunt Capacitance C0 1,1 1,8 pF
Temperature coefficient (frequency) Ä… -0.04ppm/°CMAX
Capacitance Ratio C / C1 430 600
0
Load capacitance CL 6pF
Drive Level DL 1 µW
Series resistance R1 50k&!MAX
0
Motional capacitance C1 1.8pFMAX
-20
-40
DS1485 (25°C):
Shunt capacitance C0 0.9pFMAX
Delta -60
-80
Ä…30 seconds / month (CL = 6 pF)
Insulation resistance IR 500M&!MIN
frequency -100
-120
Ä…4 minutes / month (CL = 12 pF)
Aging fa Ä…3ppm/YMAX
[ppm] -140
-160
(Ta=25°C Ä…3°C, first year)
-180
Shock resistance S.R. Ä…5ppmMAX -40 -30 -20 -10 0 10 20 30 40 50 60 70 80
(test with: 3000G x 1/2 sine wave x 3 directions) Temperature [°C]
6
PCB - Crystal Oscillator Quartz Crystals & Ceramic Resonators
Peter Mariutti: Crystal Oscillator of the C500 and C166 Microcontroller Families.
ApNote AP242005, Infineon Technologies, 1999
Peter Mariutti: Ceramic Resonator Oscillators and the C500 and C166
Microcontroller Families. ApNote AP242401, Infineon Technologies, 1999
Principal technical Differences between Quartz Crystals and Ceramic
Resonators
Ceramic Resonator Quartz Crystal
Price Factor (depends on quality) 1 2
Mechanical Shock Resistance very good good
Integrated Caps available yes no
Aging (for 10 years at room temperature) Ä… 3000 ppm Ä… 10 ppm
Initial Frequency Tolerance Ä… 2000 ... 5000 ppm Ä… 20 ppm
Temperature Characteristics Ä… 20 ... 50 ppm/°C Ä… 0. 5 ppm/°C
Load Capacitance Characteristics Ä… 100 ... 350 ppm/pF Ä… 15 ppm/pF
Oscillation Rise Time 0.01 ... 0.5 msec 1 ... 10 msec
Quality Factor (Qm) 100 ... 5 000 10 000 ... 500 000
ATmega8(L)
Internal RC Oscillator
Internal Calibrated RC
AVR051: Set-up and Use the External RC Oscillator.
Oscillator Frequency vs.
Application Note, Atmel Corporation 2002
Temperature
(the devices are calibrated
1
Short start-up time of RC oscillator:
f H"
to 8 MHz at VCC = 5V,
3 R C
max. 4 µs + 10 clock cycles
T=25°C)
20°
°C
°
°
Frequency and power consumption for C=22pF(1)/C=100pF(2), simulated values
Resistor Value (k&!) Frequency (MHz) Typical Consumption Current (mA)
1.2 11.9 / 4.54 1.0 / 0.57
Internal Calibrated RC
2.2 7.36 / 2.32 1.0 / 0.18
Oscillator Frequency vs.
3.9 4.40 / 1,41 0.57 / 0.18
Operating Voltage
8.2 1.98 0.18
(the devices are calibrated to
18.0 0.99 0.18
(1) 8 MHz at VCC = 5V, T=25°C)
C = 22 pF, and 12 pF stray capacitance (package, pad, pin, and PCB)
(2)
C = 100 pF, and 12 pF stray capacitance (package, pad, pin, and PCB), 5V 3V 5V
LPC247x
Ceramic Resonator Start-Up
Internal RC osc. temperature characteristics
CX1,2 = 50 pF
TOM WILLIAMSON: Oscillators for Microcontrollers
APPLICATION NOTE AP-155, June 1983, Intel Corp.
TS, µs
µ
µ
µ
X2
CX1,2 = 150 pF
X2
Oscillator Start-Up
(3.58 MHz Ceramic Resonator
from NTK Technical Ceramics)
7
External Memory
Zakłócenia elektromagnetyczne (1/2)
Icc [mA]
Type of memory:
80
External DS87C520,
Internal or External
74AC573,
60 oddziaływanie zewnętrznego pola elektromagnetycznego:
27C256 (70ns)
Program Memor
40 " przepięcia indukowane w zewnętrznych doprowadzeniach,
Internal DS87C520
ścieżkach drukowanych
20 (16KB of EPROM)
10
" przepięcia indukowane w wewnętrznych doprowadzeniach
10 28
1 2 4 6 8 12 14 16 18 20 22 24 26 30
(indukcyjności i pojemności połączeń struktury wewnętrznej z
Frequency [MHz]
wyprowadzeniami)
Icc [mA]
Type of memory:
50
External DS87C520,
74AC573,
40 emisja własnego pola elektromagnetycznego:
DS2064
(8Kx8 Static RAM)
30 " błędne wykonanie połączeń dla dużych prądów obciążeń
Internal or External
Internal
DS87C520
Data Memory 20
" nadmiarowe, bezzasadne generowanie dodatkowych sygnałów
(1 KB internal MOVX data memory)
10
5
1 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30
wyładowania elektrostatyczne
Frequency [MHz]
L. Baranowski: Systemy kontroli ESD.
Elektronik, kwiecień 2003
Zakłócenia elektromagnetyczne (2/2) Wyładowania elektrostatyczne (1/2)
właściwa konfiguracja systemu szereg tryboelektryczny - zestawienie materiałów pod względem biegunowości
i wielkości ładunku wytwarzanego podczas zetknięcia i rozdzielenia dwóch
" eliminacja dodatkowych układów towarzyszących, np. 8-bitowy
materiałów:
bufor linii adresowych w C51
stal
ludzka ręka: +
" eliminacja wszystkich, zbędnych zewnętrznych układów, np. drewno
" azbest
zewnętrznych pamięci w C51 bursztyn
" futro królika
guma utwardzona
" test sumy kontrolnej (CRC) całej pamięci kodu
" włókno octanowe
nikiel, miedz
" szkło
" stosowanie pamięci kodu programu programowanej maską
srebro, mosiÄ…dz
bawełna
" mika
złoto, platyna
" wyłączenie wszystkich nie używanych sygnałów sterujących, np.
" ludzki włos
jedwab octanowy
ALE, RD# i WR# w C51
" nylon
celuloid
" wełna
poliester
właściwy dobór mikrokontrolera, mechanizmów kontrolujących działanie " ołów
akryl
programu: " jedwab
polietylen
" aluminium
" programowe polipropylen
" papier
silikon
" sprzętowe
teflon 
ST7. 8-BIT MCU FAMILY USER GUIDE.
STMicroelectronics, July 2002
Wyładowania elektrostatyczne (2/2) Safety Device
czynności i odpowiadające im przykładowe ładunki w Voltach dla różnych
A microcontroller, or any programmed machine, is not an electronic
poziomów wilgotności:
wilgotność względna
brain, in spite of how it was first introduced. Rather, it is an automaton
that has a precise job to perform, taking into account events and
czynności 10% 40% 55%
conditions that are considered when the program is written.
chodzenie po dywanie 35.000 15.000 7.500
chodzenie po podłożu wykonanym z materiałów 12.000 5.000 3.000
syntetycznych
However, not all events can be taken into account; some
poruszanie się w obrębie stanowiska roboczego 6.000 800 400
occurrences are even neglected, since they are supposed to never
wyciąganie układu scalonego z szyny z tworzywa 2.000 700 400
happen. Rightly or wrongly, the code is thus made shorter.
sztucznego
wyciąganie układu scalonego z podstawki 11.500 4.000 2.000
If, however, either because the programmer made a mistake or because
wyciąganie układu scalonego ze styropianu 14.500 5.000 3.500
a hardware failure produced an unforeseen event, the program may be
wyciąganie płytki elektronicznej z opakowania z 26.000 20.000 7.000
fooled and the whole application may fail to work or even produce
tworzywa sztucznego
harmful actions.
zapakowanie płytki elektronicznej w wytłoczkę z 21.000 11.000 5.500
tworzywa sztucznego
8
Safety Programming WATCHDOG
It is up to the program to periodically rewind the clock (the watchdog
Write better code. Check what happens if a neglected condition arises.
timer) to indicate that it is still alive. Actually, it is not a full protection,
Lead the execution to a recovery routine in such an event. In short, take
since some parts of the program may crash while the part that has been
all precautions to prevent the program from crashing in any event. This
elected to rewind the timer still functions. It is up to the wise programmer
is actually a requirement, not a choice. But still, things may happen that
to find the program segment that is very unlikely to still work while some
are totally out of the control of the author of the program. For example,
other part has crashed. Well implemented, this method gives rather
an electromagnetic aggression or a power brownout to the product that
good results. Of course, resetting the program is not a good way to
is controlled by the microcontroller. Then, the proper working of the
recover from a fault, since the crash may have sent commands to the
microcontroller may not be guaranteed and the system fails. This is
external world that are themselves faulty. The watchdog timer is actually
when the watchdog can play its part.
a last ditch safety device, somewhat like a lifeboat in a shipwreck.
Methods of detecting processor failure by electronic means are
It has the ability to induce a full reset of the MCU if its counter counts
virtually non-existant. A popular method relies on a timer that acts like
down to zero prior to being reset by the software.
an alarm-clock. The clock is wound up for a certain delay. If it has not
This feature is especially useful in noisy applications.
been rewound before the expiration of this delay, the clock perform a
hardware reset to the microcontroller.
The watchdog timer is a safety device rather than a peripheral
Watchdog w C320/530 Dallas/Maxim (2/3)
Watchdog w C320/530 Dallas/Maxim (1/3)
kasowanie programowe
WD1,WD0
kasowanie programowe
/217
ustaw
wewnętrzne
WD1,WD0
/29 WTRF
zerowanie
/217
/220
ustaw EWT
wewnętrzne
główny
/29 WTRF
zerowanie
generator
/220 EWT
/223 ustaw
główny
przerwanie
WTRF
generator (adr=63h)
/223 ustaw
EWDI EA
/226
przerwanie
SETB RWT
WTRF
(adr=63h) strat/
EWDI EA
/226
kasowanie programowe
SETB RWT
Watchdog
/odświeżanie
strat/
kasowanie programowe
Watchdog
/odświeżanie
Okres wewnÄ™trznych zerowaÅ„ przez licznik Watchdoga w µs:
dzielnik
CKCON (8Eh) WD1 WD0 T2M T1M T0M MD2 MD1 MD0
wstępny @1,832 MHz @11,059 MHz @12 MHz @33 MHz
217 + 512 71.825 11.898 10.965 3.987
SMOD1 POR EPF1 PF1 WDIF WTRF EWT RWT
WDCON (0D8h)
220 + 512 572.646 94.863 87.424 31.791
223 + 512 4.579.214 758.579 699.093 245.216
Timed Access Register: 0AAh, 55h, POR/WDIF/EWT/RWT
TA (0C7h)
226 + 512 36.631.755 6.068.304 5.592.448 2.033.617
HOLD NMIES NMI TMSEL CNTCL SSEL IS1 IS0
WDTCTL (120h)
read access = 69h
write access = 5Ah
Watchdog w C320/530 Dallas/Maxim (3/3) Watchdog - MSP430
< > 5Ah
Write to WDTCTL Password
Uruchomienie Watchdoga: PUC
= 5Ah
(Watchdog
CK_CON EQU 1000 0000b ; 223 stopień podziału dzielnika wstępnego CNTCL
Mode
Restart Watchdog at 0000
(0FFFEh)
TA_AA EQU 0AAh ; dostęp do bitów w rejestrze WDCON
priority 15
TA_55 EQU 55h ; chronionych zapisem czasowym
HOLD (highest)
Reset_WD:
ACLK EN Clear
1
ORL CKCON, #CK_CON ; programowanie stopnia
(32768 Hz) POR
CLK 16-Bit Counter
; podziału dzielnika
GIE
MCLK
0
26 29 213 215 IRQA General Interrupt
MOV TA, #TA_AA ; start Watchdoga
Timer Mode Flag
MOV TA, #TA_55
SETB RWT
IS1,IS0
Reset
0
MOV TA, #TA_AA ; odblokowanie wewnętrznego zerowania Set Interrupt
WDTIFG
1
Timer Mode
MOV TA, #TA_55 ; przez Watchdog 11 10 01 00
(0FFF4h)
SETB EWT Watchdog Interrupt Enable Flag WDTIE
priority 10
9
SSEL
Watchdog Mode
TMSEL
okna czasowe


Wyszukiwarka

Podobne podstrony:
13 Power 15 www
03 Rozdzial 10 13
TIMECARD ZEST 31 10 13
I UK 10 13 1
10 12 lat 13
No Quarter Magazine 10 Web Extra Circle Oroboros Paths of Power
Klucz odpowiedzi 10 13

więcej podobnych podstron