XC886/888CLM
Multiplication/Division Unit
User’s Manual
10-7
V1.3, 2010-02
MDU, V2.1
10.5
Register Description
The 14 SFRs of the MDU consist of a control register MDUCON, a status register
MDUSTAT and 2 sets of data registers, MD0 to MD5 (which contain the operands) and
MR0 to MR5 (which contain the results).
Depending on the type of operation, the individual MDx and MRx registers assume
specific roles as summarized in
. For example, in a
multiplication operation, the low byte of the 16-bit multiplicator must be written to register
MD4 and the high byte to MD5.
Abbreviations:
•
D’end: Dividend, 1st operand of division
Table 10-3
MDx Registers
Register
Roles of registers in operations
16-bit
Multiplication
32/16-bit
Division
16/16-bit
Division
Normalize and
Shift
MD0
M’andL
D’endL
D’endL
OperandL
MD1
M’andH
D’end
D’endH
Operand
MD2
-
D’end
-
Operand
MD3
-
D’endH
-
OperandH
MD4
M’orL
D’orL
D’orL
Control
MD5
M’orH
D’orH
D’orH
-
Table 10-4
MRx Registers
Register
Roles of registers in operations
16-bit
Multiplication
32/16-bit
Division
16/16-bit
Division
Normalize and
Shift
MR0
PrL
QuoL
QuoL
ResultL
MR1
Pr
Quo
QuoH
Result
MR2
Pr
Quo
-
Result
MR3
PrH
QuoH
-
ResultH
MR4
M’orL
RemL
RemL
Control
MR5
M’orH
RemH
RemH
-
*