beautypg.com

Xch xa, @hl, Xch a, mem, Xch xa, mem – NEC PD754144 User Manual

Page 260: Xch a, reg1, Xch xa, rp

background image

CHAPTER 11 INSTRUCTION SET

260

User’s Manual U10676EJ3V0UM

XCH XA, @HL

Function: A

(HL), X

(HL+1)

Exchanges the contents of the A register with the contents of the data memory addressed by register pair HL, and

the contents of the X register with the contents of the next address.

If the contents of the L register are an odd number, however, an address whose least significant bit is ignored is

specified.

XCH A, mem

Function:

A

(mem) mem = D

7-0

: 00H to FEH

Exchanges the contents of the A register with the contents of the data memory addressed by 8-bit immediate data

mem.

XCH XA, mem

Function: A

(mem), X

(mem+1) mem = D

7-0

: 00H to FEH

Exchanges the contents of the A register with the data memory contents addressed by 8-bit immediate data mem,

and the contents of the X register with the contents of the next memory address.

The address that can be specified by mem is an even address.

XCH A, reg1

Function: A

reg1

Exchanges the contents of the A register with the contents of register reg1 (X, H, L, D, E, B, or C).

XCH XA, rp’

Function: XA

rp’

Exchanges the contents of register pair XA with the contents of register pair rp’ (XA, HL, DE, BC, XA’, HL’, DE’,

or BC’).

This manual is related to the following products: