English
Language : 

SAB80515 Datasheet, PDF (203/270 Pages) Siemens Semiconductor Group – 8-Bit Single-Chip Microcontroller Family
Instruction Set
XCH
A, <byte>
Function:
Exchange accumulator with byte variable
Description:
XCH loads the accumulator with the contents of the indicated variable, at the same
time writing the original accumulator contents to the indicated variable. The source/
destination operand can use register, direct, or register-indirect addressing.
Example:
R0 contains the address 20H. The accumulator holds the value 3FH (00111111B).
Internal RAM location 20H holds the value 75H (01110101B). The instruction
XCH A, @R0
will leave RAM location 20H holding the value 3FH (00111111 B) and 75H
(01110101B) in the accumulator.
XCH
A,Rn
Operation:
XCH
(A) ←→ (Rn)
Encoding:
Bytes:
Cycles:
1100 1rrr
1
1
XCH
A,direct
Operation:
XCH
(A) ←→ (direct)
Encoding:
Bytes:
Cycles:
1100 0101
2
1
direct address
Semiconductor Group
203