z80:Opcodes:RLD

From Learn @ Cemetech
Jump to: navigation, search

Performs a 4-bit leftward rotation of the 12-bit number whose 4 most signigifcant bits are the 4 least significant bits of A, and its 8 least significant bits are in (HL).

   ; assume W,X,Y,Z are the set of all possible hex values 0-F
   ld A,$WX
   ld (HL),$YZ
   RLD
   ; A = $WY
   ; (HL) = $ZX

Syntax

   RLD

Effects

The H and N flags are reset, P/V is parity, C is preserved, and S and Z are modified by definition.

Uses

T-States

18 t-states

See Also

RL,RLA,RLC,RLCA,RR,RRA,RRC,RRCA,RRD,SLA,SLL/SL1,SRA,SRL