8XC251SA, SB, SP, SQ USER’S MANUAL
5-10
5.3.4
Data Transfer Instructions
Data transfer instructions copy data from one register or memory location to another. These in-
structions include the move instructions (Table A-24 on page A-19) and the exchange, push, and
pop instructions (Table A-25 on page A-22). Instructions that move only a single bit are listed
with the other bit instructions in Table A-26 on page A-23.
MOV (Move) is the most versatile instruction, and its addressing modes are expanded in the
MCS 251 architecture. MOV can transfer a byte, word, or dword between any two registers or
between a register and any location in the address space.
The MOVX (Move External) instruction moves a byte from external memory to the accumulator
or from the accumulator to memory. The external memory is in the region specified by DPXL,
whose reset value is 01H. See section 3.3.2, “Dedicated Registers.”
The MOVC (Move Code) instruction moves a byte from code memory (region FF:) to the accu-
mulator.
MOVS (Move with Sign Extension) and MOVZ (Move with Zero Extension) move the contents
of an 8-bit register to the lower byte of a 16-bit register. The upper byte is filled with the sign bit
(MOVS) or zeros (MOVZ). The MOVH (Move to High Word) instruction places 16-bit immedi-
ate data into the high word of a dword register.
The XCH (Exchange) instruction interchanges the contents of the accumulator with a register or
memory location. The XCHD (Exchange Digit) instruction interchanges the lower nibble of the
accumulator with the lower nibble of a byte in on-chip RAM. XCHD is useful for BCD (binary
coded decimal) operations.
The PUSH and POP instructions facilitate storing information (PUSH) and then retrieving it
(POP) in reverse order. Push can push a byte, a word, or a dword onto the stack, using the imme-
diate, direct, or register addressing modes. POP can pop a byte or a word from the stack to a reg-
ister or to memory.
Содержание 8XC251SA
Страница 2: ......
Страница 3: ...May 1996 8XC251SA 8XC251SB 8XC251SP 8XC251SQ Embedded Microcontroller User s Manual...
Страница 18: ......
Страница 19: ...1 Guide to This Manual...
Страница 20: ......
Страница 30: ......
Страница 31: ...2 Architectural Overview...
Страница 32: ......
Страница 41: ...3 Address Spaces...
Страница 42: ......
Страница 63: ...4 Device Configuration...
Страница 64: ......
Страница 81: ...5 Programming...
Страница 82: ......
Страница 102: ......
Страница 103: ...6 Interrupt System...
Страница 104: ......
Страница 120: ......
Страница 121: ...7 Input Output Ports...
Страница 122: ......
Страница 132: ......
Страница 133: ...8 Timer Counters and Watchdog Timer...
Страница 134: ......
Страница 153: ...9 Programmable Counter Array...
Страница 154: ......
Страница 170: ......
Страница 171: ...10 Serial I O Port...
Страница 172: ......
Страница 187: ...11 Minimum Hardware Setup...
Страница 188: ......
Страница 197: ...12 Special Operating Modes...
Страница 198: ......
Страница 206: ......
Страница 207: ...13 External Memory Interface...
Страница 208: ......
Страница 239: ...14 Programming and Verifying Nonvolatile Memory...
Страница 240: ......
Страница 250: ......
Страница 251: ...A Instruction Set Reference...
Страница 252: ......
Страница 390: ......
Страница 391: ...B Signal Descriptions...
Страница 392: ......
Страница 400: ......
Страница 401: ...C Registers...
Страница 402: ......
Страница 436: ......
Страница 437: ...Glossary...
Страница 438: ......
Страница 446: ......
Страница 447: ...Index...
Страница 448: ......
Страница 458: ......