RES b,(HL)

Operation

(HL)b <- 0

Mnemonic

RES

Operands

b,(HL)

b7b6b5b4b3b2b1b0
1 1 0 0 1 0 1 1$CB
1 0 b 1 1 0

Description

Bit b in the memory location addressed by the contents of register pair HL is set. In the assembled object code, operand b is specified as follows:

Bit TestedbHex
0000$86
1001$8E
2010$96
3011$9E
4100$A6
5101$AE
6110$B6
7111$BE

Condition Bits Affected

None

Example

If the HL register pair contains $3000, then upon the execution of

	RES	4,(HL)

bit 4 in memory location $3000 is 1. Bit 0 in memory location $3000 is the least-significant bit.