beautypg.com

Maxq610 user’s guide – Maxim Integrated MAXQ610 User Manual

Page 171

background image

14-4

MAXQ610 User’s Guide

AND src

Logical AND

Description:

Performs a logical-AND between the active accumulator (Acc) and the specified src data . For the
complete list of src specifiers, reference the MOVE instruction . The PFX[n] register may be used to
supply the high byte of data for 8-bit sources .

Status Flags:

S, Z

Operation:

Acc

← Acc AND src

Encoding:

15

0

f001

1010

ssss

ssss

Example(s):

; Acc = 2345h for each example

AND A[3]

; A[3]=0F0Fh
;

→ Acc = 0305h, S=0, Z=0

AND #33h

;

→ Acc = 0001h

AND #2233h

; generates object code below
; MOVE PFX[0], #22h (smart-prefixing)
; AND #33h
;

→ Acc = 2201h

MOVE PFX[0], #0Fh
AND M0[8]

; M0[8]=0Fh (assume M0[8] is an 8-bit register)
;

→ Acc = 0305h

Special Notes: The active accumulator (Acc) is not allowed as the src for this operation .

AND Acc.

Logical AND Carry Flag with Accumulator Bit

Description:

Performs a logical-AND between the Carry (C) status flag and a specified bit of the active accumu-
lator (Acc .) and returns the result to the Carry .

Status Flags:

C

Operation:

C

← C AND Acc.

Encoding:

15

0

1001

1010

bbbb

1010

Example(s):

; Acc = 2345h, C=1 at start

AND Acc .0

; Acc .0=1

→ C=1

AND Acc .1

; Acc .1=0

→ C=0

AND C, Acc .8

; Acc .8=1

→ C=0