NO:
W90P710 Programming Guide
VERSION:
2.1
PAGE:
34
The above information is the exclusive intellectual property of Winbond Electronics and shall not be disclosed,
distributed or reproduced without permission from Winbond.
Table No.: 1200-0003-07-A
$label.temp
MOV
lr,
#0
; If r2 > r1, the system needs to remapping.
; The RO_base is W90P710 _FLASH_BASE at link-time, thus we needs it to
; Calculate the correct instruction fetch address after remapping
CMP
r2,
r1
LDRGT
lr,
=W90P710
_FLASH_BASE
; Calculate the actual fetch address where is the location of
; the label “$label.EndSysMapJump” after remapping
SUB
r3,
r3,
r2
ADD
r1,
r1,
r3
ADD
lr,
lr,
r1
; Load in the target values into the control registers
ADRL r0, $label.SystemInitData
LDMIA r0, {r1-r6}
LDR
r0,
=EBICON
; Now run critical jump code
STMIA r0, {r1-r6}
MOV
pc,
lr
$label.EndSysMapJump
; Now running from new PROM location, since code no longer exists in low memory
; Restore registers
LDMFD sp!, {r0 - r12,lr}
LDR
$w1,
[sp],
#4
MOV
sp,
$w1
B
%FT0
$label.SystemInitData
DCD rEBICON ; REFEN=1,REFMOD=0,CLKEN=1,REFRAT=0x138,WAITVT=0
DCD rROMCON ; base=W90P710 _FLASH_BASE,size=256KB,BTSIZE=32bit,
; tPA=8MCLK,tACC=8MCLK
DCD rSDCONF0; base=0x0,size=32MB,MRSET=1,AUTOPR=1,LATENCY=3MCLK,
; LENGTH=1Byte,COMPBK=2bank,DBWD=32bit,COLUM=8bit
DCD rSDCONF1; base=0x2000000,size=32MB,MRSET=1,AUTOPR=1,LATENCY=3MCLK,
; LENGTH=1Byte,COMPBK=2bank,DBWD=32bit,COLUM=8bit
DCD rSDTIME0 ; tRCD=8MCLK,tRDL=4MCLK,tRP=8MCLK,tRAS=8MCLK
DCD rSDTIME1 ; tRCD=8MCLK,tRDL=4MCLK,tRP=8MCLK,tRAS=8MCLK
ALIGN
0
MEND