WXCHG s, d
DWXCHG s, d
These commands swap data between s and d. WXCHG is for swapping word values and DWXCHG is swapping double word values.
P | M | F | S | C | T | D | Constants | |
s | O | O | O | |||||
d | O | O | O |
When START turns ON, D0 gets 100 and D1 gets 123. When IN0 turns ON, D0 and D1 swap their data. The result is as shown below: