Z80 Instruction Set
From WikiTI
Revision as of 17:42, 21 February 2006 by 207.67.57.99 (Talk)
Please format this article according to the guidelines and Wikification suggestions, then remove this {{Wikify}} notice from the article.
Data Movement
EX Three possible arguments:
EX DE, HL Swaps H with D and L with E
EX AF, AF' Swaps AF with its shadow
EX (SP), HL Swaps (SP) with L and (SP+1) with H. Index registers are also valid
EXX
Swap BC, DE and HL with their shadows
LD
Four main arguments:
LD reg, # Sets the eight or 16 bit contents of reg to #
LD reg2, reg1 Copies the contents of 8 bit reg1 to reg2
LD (imm16), reg Copies the value of 8 or 16 bit reg to 16 bit memory address imm16. Programmers should remember that 16 bit values are stored little-endian.
LD reg, (imm16) Does the opposite of LD (imm16), reg