English
Language : 

DS89C420-QCL Datasheet, PDF (79/139 Pages) Maxim Integrated Products – Ultra-High-Speed Flash Microcontroller User’s Guide
Ultra-High-Speed Flash
Microcontroller User’s Guide
PROGRAM 4: 64-BYTE BLOCK MOVE (DUAL DATA POINTER, TSL)
; SH and SL are high and low byte source address.
; DH and DL are high and low byte of destination address.
; DPS is the data pointer select. Reset condition DPTR0.
DPS
EQU 86h
; TELL ASSEMBLER ABOUT DPS
MOV
R5, #64
; NUMBER OF BYTES TO MOVE
ORL
DPS, #20h
; SET TOGGLE SELECT (TSL)
MOV
DPTR, #SHSL
; LOAD SOURCE ADDRESS
MOV
DPTR, #DHDL
; LOAD DESTINATION ADDRESS
MOVE:
; THIS LOOP IS PERFORMED R5 TIMES, IN THIS EXAMPLE 64
MOVX
A, @DPTR
; READ SOURCE DATA BYTE
MOVX
@DPTR, A
; WRITE DATA TO DESTINATION
INC
DPTR
; NEXT SOURCE ADDRESS
INC
DPTR
; NEXT DESTINATION ADDRESS
DJNZ
R5, MOVE
; FINISHED WITH TABLE?
ANL
DPS, #0DFh
; CLEAR TOGGLE SELECT
# UHSM CYCLES
2
3
3
3
3 +D
4 +CD
2 +C
1
4
3
PROGRAM 5: 64-BYTE BLOCK MOVE (DUAL DATA POINTER, AID, TSL)
; SH and SL are high and low byte source address.
; DH and DL are high and low byte of destination address.
; DPS is the data pointer select. Reset condition DPTR0.
# UHSM CYCLES
DPS
EQU 86h
; TELL ASSEMBLER ABOUT DPS
MOV
R5, #64
; NUMBER OF BYTES TO MOVE
2
ORL
DPS, #30h
; SET TOGGLE SELECT, AUTO-INC/DEC
3
MOV
DPTR, #SHSL
; LOAD SOURCE ADDRESS
3
MOV
DPTR, #DHDL
; LOAD DESTINATION ADDRESS
3
MOVE:
; THIS LOOP IS PERFORMED R5 TIMES, IN THIS EXAMPLE 64
MOVX
A, @DPTR
; READ SOURCE DATA BYTE
3 +D
MOVX
@DPTR, A
; WRITE DATA TO DESTINATION
4 +CD
DJNZ
R5, MOVE
; FINISHED WITH TABLE?
5 +C
ANL
DPS, #0CFh
; CLEAR TSL, AID
3
Note that since each pass through the loop saves additional clock cycles when compared to the single DPTR approach, efficiency
improvement when moving larger blocks is even greater using these features. Further speed improvement can be gained when exe-
cuting from internal flash program memory, since no code-fetch page misses (+C) would occur. For example, running Program 5 from
internal memory at 33MHz would require only 19.8µs (= 1/33MHz x (14 + 64 x 10)).
SECTION 7: POWER MANAGEMENT
The ultra-high-speed flash microcontroller has several features that relate to power consumption and management. They provide a
combination of controlled operation in unreliable power applications and reduced power consumption in portable or battery-powered
applications. The range of features is shown below with details to follow.
POWER MANAGEMENT
Precision Voltage Monitor
Early-Warning Power-Fail Interrupt
Power-Fail/Power-On Reset
Bandgap Select
Watchdog Wake-Up From Idle
POWER SAVING
Clock Divide Control
Idle Mode
Stop Mode
Ring Wake-Up From Stop
Power Management Mode
79 _____________________________________________________________________________________________