Daa decimal adjust accumulator – Zilog Z80380 User Manual
Page 76
5-42
Z380
™
U
SER
'
S
M
ANUAL
DC-8297-03
Z
ILOG
DAA
DECIMAL ADJUST ACCUMULATOR
DAA
Operation:
A
←
Decimal Adjust A
The accumulator is adjusted to form two 4-bit BCD digits following a binary, two’s
complement addition or subtraction on two BCD-encoded bytes. The table below indicates
the operation performed for addition (ADD, ADC, INC) or subtraction (SUB, SBC, DEC,
NEG).
C
Hex Value
H
Hex Value
Number
C
H
Before
Upper Digit
Before
Lower Digit
Added
After
After
Operation
DAA
(Bits 7-4)
DAA
(Bits 3-0)
to Byte
DAA
DAA
0
0-9
0
0-9
00
0
0
0
0-8
0
A-F
06
0
1
ADD
0
0-9
1
0-3
06
0
0
ADC
0
A-F
0
0-9
60
1
0
INC
0
9-F
0
A-F
66
1
1
(N=0)
0
A-F
1
0-3
66
1
0
1
0-2
0
0-9
60
1
0
1
0-2
0
A-F
66
1
1
1
0-3
1
0-3
66
1
0
SUB
SBC
0
0-9
0
0-9
00
0
0
DEC
0
0-8
1
6-F
FA
0
1
NEG
1
7-F
0
0-9
A0
1
0
(N=1)
1
6-F
1
6-F
9A
1
1
Flags:
S:
Set if the most significant bit of the result is set; cleared otherwise
Z:
Set if the result is zero; cleared otherwise
H:
See table above
P:
Set if the parity of the result is even; cleared otherwise
N:
Not affected
C:
See table above
Addressing
Execute
Mode
Syntax
Instruction Format
Time
Note
DAA
00100111
3
- S3F94C8 (11 pages)
- S3F80QB (29 pages)
- S3F8S19 (38 pages)
- Z51F6412 (54 pages)
- Z51F6412 (55 pages)
- Z51F6412 (96 pages)
- EZ80F93 (11 pages)
- Z16F6411 (20 pages)
- Z16F6411 (216 pages)
- EZ80F93 (13 pages)
- ZMOT0BSB (314 pages)
- ZMOT0BSB (582 pages)
- Z8F083A (14 pages)
- Z8F2480 (17 pages)
- Z8F082A (18 pages)
- Z8F082A (15 pages)
- Z8F0822 (17 pages)
- Z8F6423 (83 pages)
- Z8F2480 (19 pages)
- Z8F2480 (18 pages)
- Z8F6423 (18 pages)
- Z8F6423 (27 pages)
- Z8F6482 (50 pages)
- EZ80F91GA (469 pages)
- EZ80F915 (411 pages)
- EZ80F91NAA (34 pages)
- EZ80F91 (41 pages)
- EZ80L92 (40 pages)
- EZ80L92 (26 pages)
- EZ80L92 (79 pages)
- EZ80L92 (10 pages)
- eZ80F92 (87 pages)
- ZUSBOPTS (59 pages)
- Z16FMC6 (520 pages)
- Z8FMC16 (26 pages)
- Z16FMC6 (41 pages)
- ZUSBOPTS (38 pages)
- Z16FMC6 (8 pages)
- Z16FMC6 (26 pages)
- ZMOT1AHH (25 pages)
- ZMOT0BSB (34 pages)
- EZ80F915 (78 pages)
- EZ80190 (87 pages)
- EZ80L92 (86 pages)
- EZ80F91GA (127 pages)