Bit b, (IX/Y+d)
Bit Test
Operation
Z ← ~(IX/Y+d)[b]
Description
The (IX/Y+d) operand is an 8-bit value stored at the memory location specified by the
contents of the Index Register, IX or IY, added to the two's-complement displacement d.
This instruction tests bit b of this 8-bit value and sets the 0 Flag (Z) if the bit is 0. The Z
Flag is reset if bit b of operand (HL) is a one.
Condition Bits Affected
S
Z
H
P/V
N
C
Attributes
Mnemonic
BIT
BIT.S
BIT.L
BIT
BIT.S
BIT.L
= binary code
kk
object code, as indicated in
UM007714-0908
Undefined.
Set if bit b is 0; reset otherwise.
Set.
Undefined.
Reset.
Not affected.
Operand
ADL Mode
X
b,(IX+d)
1
b,(IX+d)
0
b,(IX+d)
X
b,(IY+d)
1
b,(IY+d)
0
b,(IY+d)
, where
01 bbb 110
Table
Cycle Opcode (hex)
5
DD, CB, dd, kk
6
52, DD, CB, dd, kk
6
49, DD, CB, dd, kk
5
FD, CB, dd, kk
6
52, FD, CB, dd, kk
6
49, FD, CB, dd, kk
identifies the bit tested and assembled into the
bbb
45.
®
eZ80
CPU
User Manual
108
CPU Instruction Set
Need help?
Do you have a question about the eZ80 and is the answer not in the manual?
Questions and answers