C8051F340/1/2/3/4/5/6/7
Table 9.1. CIP-51 Instruction Set Summary (Continued)
Mnemonic | Description | Bytes | Clock | |
Cycles | ||||
|
|
| ||
XCH A, @Ri | Exchange indirect RAM with A | 1 | 2 | |
XCHD A, @Ri | Exchange low nibble of indirect RAM with A | 1 | 2 | |
| Boolean Manipulation |
|
| |
CLR C | Clear Carry | 1 | 1 | |
CLR bit | Clear direct bit | 2 | 2 | |
SETB C | Set Carry | 1 | 1 | |
SETB bit | Set direct bit | 2 | 2 | |
CPL C | Complement Carry | 1 | 1 | |
CPL bit | Complement direct bit | 2 | 2 | |
ANL C, bit | AND direct bit to Carry | 2 | 2 | |
ANL C, /bit | AND complement of direct bit to Carry | 2 | 2 | |
ORL C, bit | OR direct bit to carry | 2 | 2 | |
ORL C, /bit | OR complement of direct bit to Carry | 2 | 2 | |
MOV C, bit | Move direct bit to Carry | 2 | 2 | |
MOV bit, C | Move Carry to direct bit | 2 | 2 | |
JC rel | Jump if Carry is set | 2 | 2/4 | |
JNC rel | Jump if Carry is not set | 2 | 2/4 | |
JB bit, rel | Jump if direct bit is set | 3 | 3/5 | |
JNB bit, rel | Jump if direct bit is not set | 3 | 3/5 | |
JBC bit, rel | Jump if direct bit is set and clear bit | 3 | 3/5 | |
| Program Branching |
|
| |
ACALL addr11 | Absolute subroutine call | 2 | 4 | |
LCALL addr16 | Long subroutine call | 3 | 5 | |
RET | Return from subroutine | 1 | 6 | |
RETI | Return from interrupt | 1 | 6 | |
AJMP addr11 | Absolute jump | 2 | 4 | |
LJMP addr16 | Long jump | 3 | 5 | |
SJMP rel | Short jump (relative address) | 2 | 4 | |
JMP @A+DPTR | Jump indirect relative to DPTR | 1 | 4 | |
JZ rel | Jump if A equals zero | 2 | 2/4 | |
JNZ rel | Jump if A does not equal zero | 2 | 2/4 | |
CJNE A, direct, rel | Compare direct byte to A and jump if not equal | 3 | 3/5 | |
CJNE A, #data, rel | Compare immediate to A and jump if not equal | 3 | 3/5 | |
CJNE Rn, #data, rel | Compare immediate to Register and jump if not equal | 3 | 3/5 | |
CJNE @Ri, #data, rel | Compare immediate to indirect and jump if not equal | 3 | 4/6 | |
DJNZ Rn, rel | Decrement Register and jump if not zero | 2 | 2/4 | |
DJNZ direct, rel | Decrement direct byte and jump if not zero | 3 | 3/5 | |
NOP | No operation | 1 | 1 |
Rev. 0.5 | 77 |