KS57C2308/P2308/C2316/P2316
POWER-DOWN
8-5
+
+
PROGRAMMING TIP — Reducing Power Consumption for Key Input Interrupt Processing
The following code shows real-time clock and interrupt processing for key inputs to reduce power consumption. In
this example, the system clock source is switched from the main system clock to a subsystem clock and the LCD
display is turned on:
KEYCLK
DI
CALL
MA2SUB
; Main system clock
→
subsystem clock switch subroutine
SMB
15
LD
EA,#00H
LD
P2,EA
; All key strobe outputs to low level
LD
A,#3H
LD
IMOD2,A
; Select KS0–KS7 enable
SMB
0
BITR
IRQW
BITR
IRQ2
BITS
IEW
BITS
IE2
CLKS1
CALL
WATDIS
; Execute clock and display changing subroutine
BTSTZ
IRQ2
JR
CIDLE
CALL
SUB2MA
; Subsystem clock
→
main system clock switch
subroutine
EI
RET
CIDLE
IDLE
; Engage idle mode
NOP
NOP
NOP
JPS
CLKS1
NOTE
You must program at least three NOP instructions after IDLE and STOP instructions, to avoid flowing
of leakage current due to the floating state in the internal bus.
Summary of Contents for KS57C2308
Page 30: ...ADDRESS SPACES KS57C2308 P2308 C2316 P2316 2 22 NOTES ...
Page 168: ...SAM47 INSTRUCTION SET KS57C2308 P2308 C2316 P2316 5 94 NOTES ...
Page 170: ......
Page 206: ...POWER DOWN KS57C2308 P2308 C2316 P2316 8 8 NOTES ...
Page 210: ...RESET KS57C2308 P2308 C2316 P2316 9 4 NOTES ...
Page 222: ...I O PORTS KS57C2308 P2308 C2316 P2316 10 12 NOTES ...
Page 272: ...LCD CONTROLLER DRIVER KS57C2308 P2308 C2316 P2316 12 24 NOTES ...
Page 280: ...SERIAL I O INTERFACE KS57C2308 P2308 C2316 P2316 13 8 NOTES ...
Page 294: ...MECHANICAL DATA KS57C2308 P2308 C2316 P2316 15 2 NOTES ...
Page 310: ...KS57P2308 P2316 OTP KS57C2308 P2308 C2316 P2316 16 16 NOTES ...
Page 318: ......
Page 320: ......
Page 322: ......
Page 325: ......
Page 327: ......