299
3. Instructions
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Data Movement Instructions
3
XCHG/XCGL
Hint
Example Programming
To exchange 3 or more words, use
XFER(070) to transfer the words to a third set
of words (a buffer) as shown in this diagram.
When CIO 0.00 is ON in this example, the
content of D100 is exchanged with the content
of D200.
When CIO 0.00 is ON in this example, the
contents of D100 and D101 are exchanged with
the contents of D200 and D201.
E2
E1
Buffer
1
st
XFER(070)
operation
2
nd
XFER(070)
operation
3
rd
XFER(070)
operation
D100 D200
D100 D200
D100
D200
0.00
D100
D200
D100
D101
D100
D101
D200
D201
D200
D201
0.00