INSTRUCTION SET

ADDC A,@Rr Add Carry and Data Memory Contents to Accumulator

101111 0 0 0r i

The content of the carry bit is added to accumulator location 0 and the carry bit c;:leared. Then the contents of the resident data memory location aqdressed by register Or' bits 0-5*are added to the accumulator. Carry is affected.

(A) ... (A)+«Rr))+(C) r=0-1

Example: ADDMC: MOV R1,#40 ;MOVE '40'DEC TO REG 1

AD DC A,@R1 ;ADD CARRY AND LOCATION 40 ;CONTENTS TO ACC

ADDC A,#data Add Carry and Immediate Data to Accumulator

 

I0 0 0 1 I0 0 1 1 I

Id7 de d5 d4 Id3 d2 d1 do I

 

This is a 2-cycle instruction. The content of the

 

carry bit is added to accumulator location 0 and

 

the carry bit cleared. Then the specified data is

 

addec;l to the accumulator. Carry is affected.

 

(A)-- (A)+data+(C)

 

Example:

ADDC A,#225

;ADD CARRY AND '225'DEC

 

 

;TO ACC

ANL A,R r

Logical AND Accumulator With Register Mask

 

1010111rrri

 

Data in the accumulator is logically ANDed with the mask contained in working register or'.

(A) -- (A) AND (Rr) r=0-7

Example: ANDREG: ANL A,R3 ;'AND'ACC CONTENTS WITH MASK ;IN REG 3

ANL A,@R r Logical AND Accumulator With Memory Mask

101011 000r i

Data in the accumulator is logically ANDed with the mask contained in the data memory location referenced by register or',bits 0-5~

(A)-- (A) AND «Rr)) r=0-1

Example: ANDDM: MOV RO,#03FH ;MOVE '3F'HEX TO REG 0 ANL A, @RO ;'AND'ACC CONTENTS WITH

;MASK IN LOCATION 63

Mnemonics copyright Intel Corporation 1976.

. '0-6for 8039/8049

4-10

Page 83
Image 83
Intel mcs-48 Addc A,#data Add Carry and Immediate Data to Accumulator, ANL A,@R r Logical and Accumulator With Memory Mask