18 inTeGeR MulTiPlieR
S1C63003/004/008/016 TeChniCal Manual
Seiko epson Corporation
18-3
(Rev. 1.1)
ldb
%ext, rslt_data@h
ldb
%xl, rslt_data@l
; Set result store address
nop
nop
nop
; Dummy instructions to wait end of operation
;
bit
[%y], 0b0100
jrnz overflow
; Jump to error routine if VF = "1"
;
add
%y, -4
; Set DRL again
;
ldb
%ba, [%y]+
ldb
[%x]+, %ba
; Store result (quotient) into RAM
ldb
%ba, [%y]+
ldb
[%x]+, %ba
; Store result (remainder) into RAM
i/O Memory of integer Multiplier
18.6
Table 18.6.1 shows the I/O addresses and the control bits for the integer multiplier.
6.1 Control bits of integer multiplier
Table 18.
Address
Register name R/W Default
Setting/data
Function
FF16H D3
MDCKe (
*
5)
R/W
0
1 Enable
0 Disable
Integer multiplier clock enable
D2 SGCKE
R/W
0
1 Enable
0 Disable
Sound generator clock enable
D1 SWCKE
R/W
0
1 Enable
0 Disable
Stopwatch timer clock enable
D0 RTCKE
R/W
0
1 Enable
0 Disable
Clock timer clock enable
FF70H
(
*
5)
D3
SR3
R/W
×
0H–FH
Source register (low-order 4 bits)
SR0 = LSB
D2
SR2
R/W
×
D1
SR1
R/W
×
D0
SR0
R/W
×
FF71H
(
*
5)
D3
SR7
R/W
×
0H–FH
Source register (high-order 4 bits)
SR7 = MSB
D2
SR6
R/W
×
D1
SR5
R/W
×
D0
SR4
R/W
×
FF72H
(
*
5)
D3
DRl3
R/W
×
0H–FH
Low-order 8-bit destination register
(low-order 4 bits)
DRL0 = LSB
D2
DRl2
R/W
×
D1
DRl1
R/W
×
D0
DRl0
R/W
×
FF73H
(
*
5)
D3
DRl7
R/W
×
0H–FH
Low-order 8-bit destination register
(high-order 4 bits)
DRL7 = MSB
D2
DRl6
R/W
×
D1
DRl5
R/W
×
D0
DRl4
R/W
×
FF74H
(
*
5)
D3
DRh3
R/W
×
0H–FH
High-order 8-bit destination register
(low-order 4 bits)
DRH0 = LSB
D2
DRh2
R/W
×
D1
DRh1
R/W
×
D0
DRh0
R/W
×
FF75H
(
*
5)
D3
DRh7
R/W
×
0H–FH
High-order 8-bit destination register
(high-order 4 bits)
DRH7 = MSB
D2
DRh6
R/W
×
D1
DRh5
R/W
×
D0
DRh4
R/W
×
FF76H
(
*
5)
D3
nF
R
0
1 Negative
0 Positive
Negative flag
D2
VF
R
0
1 Overflow
0 No
Overflow flag
D1
ZF
R
0
1 Zero
0 No
Zero flag
D0
CalMD
R/W
0
1 Division (W)
Run (R)
0 Multiplication (W)
Stop (R)
Calculation mode selection (writing)
Operation status (reading)
*
1 Initial value at initial reset
*
2 Not set in the circuit
*
3 Constantly "0" when being read
*
4 Unused in the S1C63003/004/008
*
5 Unused in the S1C63003/004
*
6 Unused in the S1C63003