Download Print this page

Siemens SAB 80515 Series User Manual page 139

8-bit single-chip microcontroller family

Advertisement

ADDC
A, < src-byte>
Function:
Add with carry
Description:
ADDC simultaneously adds the byte variable indicated, the carry flag and the
accumulator contents, leaving the result in the accumulator. The carry and auxiliary
carry flags are set, respectively, if there is a carry out of bit 7 or bit 3, and cleared
otherwise. When adding unsigned integers, the carry flag indicates an overflow
occurred.
OV is set if there is a carry out of bit 6 but not out of bit 7, or a carry out of bit 7 but
not out of bit 6; otherwise OV is cleared. When adding signed integers, OV indicates
a negative number produced as the sum of two positive operands or a positive sum
from two negative operands.
Four source operand addressing modes are allowed: register, direct, register-
indirect, or immediate.
Example:
The accumulator holds 0C3 H (11000011B) and register 0 holds 0AA H (10101010B)
with the carry flag set. The instruction
ADDC
will leave 6E H (01101110B) in the accumulator with AC cleared and both the carry
flag and OV set to 1.
ADDC
A,Rn
Operation:
ADDC
(A) ← (A) + (C) + (Rn)
Encoding:
0 0 1 1
Bytes:
1
Cycles:
1
ADDC
A,direct
Operation:
ADDC
(A) ← (A) + (C) + (direct)
Encoding:
0 0 1 1
Bytes:
2
Cycles:
1
Semiconductor Group
A,R0
1 r r r
0 1 0 1
direct address
*
139
Instruction Set

Advertisement

loading

This manual is also suitable for:

Sab 80c515Sab 80c535Sab 80535Sab 80515k