APPENDIX E INITIALIZATION ROUTINE
S1C17M12/M13 TECHNICAL MANUAL
Seiko Epson Corporation
AP-E-1
(Rev. 1.2)
Appendix E Initialization Routine
The following lists typical vector tables and initialization routines:
boot.s
.org 0x8000
.section
.rodata
...
(1)
; ======================================================================
; Vector table
; ======================================================================
; interrupt vector interrupt
; number offset source
.long BOOT
; 0x00 0x00 reset
...
(2)
.long unalign_handler
; 0x01 0x04 unalign
.long nmi_handler
; 0x02 0x08 NMI
.long int03_handler
; 0x03 0x0c -
.long svd3_handler
; 0x04 0x10 SVD3
.long pport_handler
; 0x05 0x14 PPORT
.long int06_handler
; 0x06 0x18 -
.long clg_handler
; 0x07 0x1c CLG
.long int08_handler
; 0x08 0x20 –
.long t16_0_handler
; 0x09 0x24 T16 ch0
.long uart3_0_handler
; 0x0a 0x28 UART3 ch0
.long t16_1_handler
; 0x0b 0x2c T16 ch1
.long spia_0_handler
; 0x0c 0x30 SPIA ch0
.long i2c_0_handler
; 0x0d 0x34 I2C ch0
.long t16b_0_handler
; 0x0e 0x38 T16B ch0
.long t16_2_handler
; 0x0f 0x3c T16 ch2
.long t16_3_handler
; 0x10 0x40 T16 ch3
.long remc2_handler
; 0x11 0x44 REMC2
.long adc12a_0_handler ; 0x12 0x48 ADC12A
.long ledc_handler
; 0x13 0x4c LEDC
.long spia_1_handler
; 0x14 0x50 SPIA ch1
.long int15_handler
; 0x15 0x54 -
.long int16_handler
; 0x16 0x58 -
.long int17_handler
; 0x17 0x5c -
.long int18_handler
; 0x18 0x60 -
.long int19_handler
; 0x19 0x64 -
.long int1a_handler
; 0x1a 0x68 -
.long int1b_handler
; 0x1b 0x6c -
.long int1c_handler
; 0x1c 0x70 -
.long int1d_handler
; 0x1d 0x74 -
.long int1e_handler
; 0x1e 0x78 -
.long int1f_handler
; 0x1f 0x7c -
; ======================================================================
; Program code
; ======================================================================
.text
...
(3)
.align 1
BOOT:
; ===== Initialize ===========================================
; ----- Stack pointer --------------------
Xld.a %sp, 0x7c0
...
(4)
; ----- Memory controller ----------------
Xld.a %r1, 0x41b0 ; FLASHC register address
; Flash read wait cycle
Xld.a %r0, 0x00 ; 0x00 = No wait
ld.b [%r1], %r0 ; [0x41b0] <= 0x00
...
(5)
; ===== Main routine =========================================
...