![Renesas RL78/G1H Скачать руководство пользователя страница 849](http://html1.mh-extra.com/html/renesas/rl78-g1h/rl78-g1h_user-manual_1440449849.webp)
CHAPTER 29 BCD CORRECTION CIRCUIT
Page 831 of 920
CHAPTER 29 BCD CORRECTION CIRCUIT
29.1
BCD Correction Circuit Function
The result of addition/subtraction of the BCD (binary-coded decimal) code and BCD code can be obtained as BCD
code with this circuit.
The decimal correction operation result is obtained by performing addition/subtraction having the A register as the
operand and then adding/ subtracting the BCD correction result register (BCDADJ).
29.2
Registers Used by BCD Correction Circuit
The BCD correction circuit uses the following registers.
• BCD correction result register (BCDADJ)
29.2.1
BCD correction result register (BCDADJ)
The BCDADJ register stores correction values for obtaining the add/subtract result as BCD code through
add/subtract instructions using the A register as the operand.
The value read from the BCDADJ register varies depending on the value of the A register when it is read and
those of the CY and AC flags.
The BCDADJ register is read by an 8-bit memory manipulation instruction.
Reset input sets this register to undefined.
Figure 29 - 1 Format of BCD correction result register (BCDADJ)
Address: F00FEH
After reset: Undefined
Symbol
7
6
5
4
3
2
1
0
Содержание RL78/G1H
Страница 941: ...R01UH0575EJ0120 RL78 G1H...