Instruction |
Cycles |
Flags |
Affects |
Refs |
Description |
Details |
Microchip Menomics |
byte-oriented operations |
MOV W,#lit |
1 |
- |
W |
lit |
Move literal into
W (
W =
lit ) |
Users Manual p103 |
MOVLW lit |
MOV W,fr |
1 |
Z |
W |
fr |
Move fr into
W (
W =
fr ) |
Users Manual p95 |
MOVF fr,0 |
MOV fr,W |
1 |
- |
fr |
W |
Move W into
fr (
fr =
W ) |
Users Manual p89 |
MOVWF fr |
MOV fr,#lit |
2 |
- |
W
fr |
lit |
Move literal into
fr (
fr =
lit ) |
See: mov W, #lit;
mov fr, W |
MOVLW lit; MOVWF fr |
MOV fr1,fr2 |
2 |
Z |
W
fr1 |
fr2 |
Move fr2 into
fr1 (
fr1 =
fr2 ) |
See: mov W, fr2;
mov fr1, W |
MOVF fr2,0; MOVWF fr1 |
ADD W,fr |
1 |
C
DC
Z |
W |
fr |
Add fr into
W (
W +=
fr ) |
Users Manual p70 |
ADDWF fr,0 |
ADD fr,W |
1 |
C
DC
Z |
fr |
W |
Add W into
fr (
fr +=
W ) |
Users Manual p69 |
ADDWF fr,1 |
ADD fr,#lit |
2 |
C
DC
Z |
W
fr |
lit |
Add literal into
fr (
fr +=
W =
lit ) |
See: mov W, #lit;
add fr, W |
MOVLW lit; ADDWF fr,1 |
ADD fr1,fr2 |
2 |
C
DC
Z |
W
fr1 |
fr2 |
Add fr2 into
fr1 (
fr1 +=
W =
fr2 ) |
See: mov W, fr2;
add fr1, W |
MOVF fr2,0; ADDWF fr1,1 |
MOV W,fr-W |
1 |
C
DC
Z |
W |
fr |
Move fr -
W into
W (
W -=
fr ) |
Users Manual p97 |
SUBWF fr,0 |
SUB fr,W |
1 |
C
DC
Z |
fr |
W |
Subtract W from
fr (
fr -=
W ) |
Users Manual p124 |
SUBWF fr,1 |
SUB fr,#lit |
2 |
C
DC
Z |
W
fr |
lit |
Subtract lit from
fr (
fr -=
W =
lit ) |
See: mov W, #lit;
sub fr, W |
MOVLW lit; SUBWF fr,1 |
SUB fr1,fr2 |
2 |
C
DC
Z |
W
fr1 |
fr2 |
Subtract fr2 from
fr1 (
fr1 -=
W =
fr2 ) |
See: mov W, fr2;
sub fr1, W |
MOVF fr2,0; SUBWF fr1,1 |
AND W,#lit |
1 |
Z |
W |
lit |
AND literal into
W (
W &=
lit ) |
Users Manual p73 |
ANDLW lit |
AND W,fr |
1 |
Z |
W |
fr |
AND fr into
W (
W &=
fr ) |
Users Manual p72 |
ANDWF fr,0 |
AND fr,W |
1 |
Z |
fr |
W |
AND W into
fr (
fr &=
W ) |
Users Manual p71 |
ANDWF fr,1 |
AND fr,#lit |
2 |
Z |
W
fr |
lit |
AND literal into
fr (
fr &=
W =
lit ) |
See: mov W, #lit;
and fr, W |
MOVLW lit; ANDWF fr,1 |
AND fr1,fr2 |
2 |
Z |
W
fr1 |
fr2 |
AND fr2 into
fr1 (
fr1 &=
W =
fr2 ) |
See: mov W, fr2;
and fr, W |
MOVF fr2,0; ANDWF fr,1 |
OR W,#lit |
1 |
Z |
W |
lit |
OR literal into
W (
W |=
lit ) |
Users Manual p111 |
IORLW lit |
OR W,fr |
1 |
Z |
W |
fr |
OR fr into
W (
W |=
fr ) |
Users Manual p110 |
IORWF fr,0 |
OR fr,W |
1 |
Z |
fr |
W |
OR W into
fr (
fr |=
W ) |
Users Manual p109 |
IORWF fr,1 |
OR fr,#lit |
2 |
Z |
W
fr |
lit |
OR literal into
fr (
fr |=
W =
lit ) |
See: mov W, #lit;
or fr, W |
MOVLW lit; IORWF fr,1 |
OR fr1,fr2 |
2 |
Z |
W
fr1 |
fr2 |
OR fr2 into
fr1 (
fr1 |=
W =
fr2 ) |
See: mov W, fr2;
or fr1, W |
MOVF fr2,0; IORWF fr1,1 |
XOR W,#lit |
1 |
Z |
W |
lit |
XOR literal into
W (
W ^=
lit ) |
Users Manual p130 |
XORLW lit |
XOR W,fr |
1 |
Z |
W |
fr |
XOR fr into
W (
W ^=
fr ) |
Users Manual p129 |
XORWF fr,0 |
XOR fr,W |
1 |
Z |
fr |
W |
XOR W into
fr (
fr ^=
W ) |
Users Manual p128 |
XORWF fr,1 |
XOR fr,#lit |
2 |
Z |
W
fr |
lit |
XOR literal into
fr (
fr ^=
W =
lit ) |
See: mov W, #lit;
xor fr, W |
MOVLW lit; XORWF fr,1 |
XOR fr1,fr2 |
2 |
Z |
W
fr1 |
fr2 |
XOR fr2 into
fr1 (
fr1 ^=
W =
fr2 ) |
See: mov W, fr2;
xor fr1, W |
MOVF fr2,0; XORWF fr1,1 |
CLR W |
1 |
Z |
W |
- |
Clear W (
W = 0 ) |
Users Manual p79 |
CLRW |
CLR fr |
1 |
Z |
fr |
- |
Clear fr (
fr = 0 ) |
Users Manual p78 |
CLRF fr |
MOV W,++fr |
1 |
Z |
W |
fr |
Move fr + 1 into
W (
W = 1 +
fr ) |
Users Manual p99 |
INCF fr,0 |
INC fr |
1 |
Z |
fr |
fr |
Increment fr (
fr = 1 +
fr ) |
Users Manual p84 |
INCF fr,1 |
MOV W,--fr |
1 |
Z |
W |
fr |
Move fr - 1 into
W (
W = -1 +
fr ) |
Users Manual p98 |
DECF fr,0 |
DEC fr |
1 |
Z |
fr |
fr |
Decrement fr (
fr = -1 +
fr ) |
Users Manual p82 |
DECF fr,1 |
MOV W,<FR |
1 |
C |
W |
fr |
Move left-rotated fr
into W (
W =
C +
fr << 1
fr ) |
Users Manual p100 |
RLF fr,0 |
RL fr |
1 |
C |
fr |
fr |
Rotate left fr (
fr =
C +
fr << 1
fr ) |
Users Manual p118 |
RLF fr,1 |
MOV W,>>fr |
1 |
C |
W |
fr |
Move right-rotated fr
into W (
W =
C * 128 +
fr >> 1
fr ) |
Users Manual p101 |
RRF fr,0 |
RR fr |
1 |
C |
fr |
fr |
Rotate right fr (
fr =
C * 128 +
fr >> 1
fr ) |
Users Manual p119 |
RRF fr,1 |
MOV W,<>fr |
1 |
- |
W |
fr |
Move nibble-swapped fr
into W (
W = ((
fr &
0xF0 ) >> 4 ) | ((
fr &
0x0F ) << 4 )
fr ) |
Users Manual p102 |
SWAPF fr,0 |
SWAP fr |
1 |
- |
fr |
fr |
Swap nibbles in fr (
fr = ((
fr &
0xF0 ) >> 4 ) | ((
fr &
0x0F ) << 4 )
fr ) |
Users Manual p126 |
SWAPF fr,1 |
NOT W |
1 |
Z |
W |
W |
Perform not on W
( W =
0xFF ^
W ) |
See: xor w,#$FF |
XORLW 0FFh |
MOV W,/fr |
1 |
Z |
W |
fr |
Move not'd fr into
W (
W =
0xFF ^
fr ) |
Users Manual p96 |
COMF fr,0 |
NOT fr |
1 |
Z |
fr |
fr |
Perform not on fr (
fr =
0xFF ^
fr ) |
Users Manual p108 |
COMF fr,1 |
TEST W |
1 |
Z |
W |
W |
Test W for
zero (
W = 0 |
W ) |
See: or W,#lit |
IORLW 0 |
TEST fr |
1 |
Z |
fr |
fr |
Test fr for
zero (
fr = 0 |
fr ) |
Users Manual p127 |
MOVF fr,1 |
TSTN w |
1 |
Z |
W |
W |
Test W for $FF
( W ) |
See: xor W,#$FF |
XORLW 0FFh |
TSTN fr |
1 |
Z |
fr |
fr |
Test fr for $FF (
fr ) |
See: mov W,/fr |
COMF fr,1 |
bit-oriented operations |
CLRB bit |
1 |
- |
fr
bit |
fr |
Clear bit ( fr,bit = !( 1 <<
bit ) &
fr ) |
Users Manual p81 |
BCF bit |
CLC |
1 |
C |
- |
- |
Clear carry ( -
) |
See: CLRB bit |
BCF 3,0 |
CLZ |
1 |
Z |
- |
- |
Clear zero ( - ) |
See: CLRB bit |
BCF 3,2 |
SETB bit |
1 |
- |
fr
bit |
fr |
Set bit ( fr,bit = ( 1 <<
bit ) |
fr ) |
Users Manual p121 |
BSF bit |
STC |
1 |
C |
- |
- |
Set carry ( - ) |
See: setb 3.0 |
BSF 3,0 |
STZ |
1 |
Z |
- |
- |
Set zero ( - ) |
See: setb 3.2 |
BSF 3,2 |
ADDB fr,bit |
2 |
Z |
fr |
bit |
Add bit into
fr (
fr +=
bit ) |
See: snb bit;
inc fr |
BTFSC bit; INCF fr,1 |
ADDB fr,/bit |
2 |
Z |
fr |
bit |
Add not bit into
fr (
fr += !
bit ) |
See: sb bit;
inc fr |
BTFSS bit; INCF fr,1 |
SUBB fr,bit |
2 |
Z |
fr |
bit |
Subtract bit from
fr (
fr -=
bit ) |
See: snb bit;
dec fr |
BTFSC bit; DECF fr,1 |
SUBB fr,/bit |
2 |
Z |
fr |
bit |
Subtract not bit from
fr (
fr -= !
bit ) |
See: sb bit;
dec fr |
BTFSS bit; DECF fr,1 |
MOVB bit1,bit2 |
4 |
- |
bit1 |
bit2 |
Move bit2 into
bit1 ( bit1
= bit2 ) |
See: sb bit2;
clrb bit1;
snb bit2;
setb bit1 |
BTFSS bit2; BCF bit1; BTFSC bit2; BSF bit1 (doesn't work) |
MOVB bit1,/bit2 |
4 |
- |
bit1 |
bit2 |
Move not bit2 into
bit1 ( bit1
= ! bit2 ) |
See: snb bit2;
clrb bit1;
sb bit2;
setb bit1 |
BTFSC bit2; BCF bit1; BTFSS bit2; BSF bit1 (doesn't work) |
inc/dec-conditional branches |
MOVSZ W,++fr |
1 |
- |
W |
fr |
Move fr + 1 into W,
skip if zero (
W = 1 +
fr ) |
Users Manual p106 |
INCFSZ fr,0 |
INCSZ fr |
1 |
- |
fr
PC |
fr |
Increment fr , skip
if zero ( ++
fr == 0 ? PC++ ) |
Users Manual p85 |
INCFSZ fr,1 |
IJNZ fr,addr |
2 * |
- |
fr
PC |
fr |
Increment fr , jump
if not zero ( ++
fr == 0 ?
PC = addr ) |
See: incsz fr;
jmp addr |
INCFSZ fr,1; GOTO addr |
MOVSZ W,--fr |
1 |
- |
W
PC |
fr |
Move fr - 1 into W,
skip if zero ( (
W = --fr ) == 0 ?
PC++ ) |
Users Manual p105 |
DECFSZ fr,0 |
DECSZ fr |
1 |
- |
fr
PC |
fr |
Decrement fr , skip
if zero ( --
fr == 0 ? PC++ ) |
Users Manual p83 |
DECFSZ fr,1 |
DJNZ fr,addr |
2 * |
- |
fr
PC |
fr |
Decrement fr , jump
if not zero ( --
fr == 0 ?
PC = addr ) |
See: decsz fr;
jmp addr |
DECFSZ fr,1; GOTO addr |
compare-conditional branches (see also:
Program Flow Methods - Comparing values) |
CSE fr,#lit |
3 |
C
DC
Z |
W
PC |
fr
lit |
Compare, skip if equal ( (
W =
lit -
fr ) == 0 ? PC++ ) |
See: mov W, #lit;
mov W, fr-w;
sb 3.2 |
MOVLW lit; SUBWF fr,0; BTFSS 3,2 |
CSE fr1,fr2 |
3 |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, skip if equal ( (
W =
fr1 -
fr2 ) == 0 ? PC++ ) |
See: mov W, fr2;
mov W, fr1-w;
sb 3.2 |
MOVF fr2,0; SUBWF fr1,0; BTFSS 3,2 |
CSNE fr,#lit |
3 |
C
DC
Z |
W
PC |
fr
lit |
Compare, skip if not equal ( (
W =
lit -
fr ) != 0 ? PC++ ) |
See: mov W, #lit;
mov W, fr-w;
snb 3.2 |
MOVLW lit; SUBWF fr,0; BTFSC 3,2 |
CSNE fr1,fr2 |
3 |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, skip if not equal ( (
W =
fr1 -
fr2 ) != 0 ? PC++ ) |
See: mov W, fr2;
mov W, fr1-w;
snb 3.2 |
MOVF fr2,0; SUBWF fr1,0; BTFSC 3,2 |
CSA fr,#lit |
3 |
C
DC
Z |
W
PC |
fr
lit |
Compare, skip if above ( (
W =
lit -
fr ) < 0 ? PC++ ) |
See: mov W, #/lit;
add W, fr;
sb 3.0 |
MOVLW /lit; ADDWF fr,0; BTFSS 3,0 |
CSA fr1,fr2 |
3 |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, skip if above ( (
W =
fr1 -
fr2 ) < 0 ? PC++ ) |
See: mov W, fr1;
mov W, fr2-w;
snb 3.0 |
MOVF fr1,0; SUBWF fr2,0; BTFSC 3,0 |
CSAE fr,#lit |
3 |
C
DC
Z |
W
PC |
fr
lit |
Compare, skip if above or equal ( (
W =
lit -
fr ) <= 0 ? PC++ ) |
See: mov W, #lit;
mov W, fr-w;
sb 3.0 |
MOVLW lit; SUBWF fr,0; BTFSS 3,0 |
CSAE fr1,fr2 |
3 |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, skip if above or equal ( (
W =
fr1 -
fr2 ) <= 0 ? PC++ ) |
See: mov W, fr2;
mov W, fr1-w;
sb 3.0 |
MOVF fr2,0; SUBWF fr1,0; BTFSS 3,0 |
CSB fr,#lit |
3 |
C
DC
Z |
W
PC |
fr
lit |
Compare, skip if below ( (
W =
lit -
fr ) > 0 ? PC++ ) |
See: mov W, #lit;
mov W, fr-w;
snb 3.0 |
MOVLW lit; SUBWF fr,0; BTFSC 3,0 |
CSB fr1,fr2 |
3 |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, skip if below ( (
W =
fr1 -
fr2 ) > 0 ? PC++ ) |
See: mov W, fr2;
mov W, fr1-w;
snb 3.0 |
MOVF fr2,0; SUBWF fr1,0; BTFSC 3,0 |
CSBE fr,#lit |
3 |
C
DC
Z |
W
PC |
fr
lit |
Compare, skip if below or equal ( (
W =
lit -
fr ) >= 0 ? PC++ ) |
See: mov W, #/lit;
add W, fr;
snb 3.0 |
MOVLW /lit; ADDWF fr,0; BTFSC 3,0 |
CSBE fr1,fr2 |
3 |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, skip if below or equal ( (
W =
fr1 -
fr2 ) >= 0 ? PC++ ) |
See: mov W, fr1;
mov W, fr2-w;
sb 3.0 |
MOVF fr1,0; SUBWF fr2,0; BTFSS 3,0 |
bit-conditional branches |
CJE fr,#lit,addr |
4 * |
C
DC
Z |
W
PC |
fr
lit |
Compare, jump if equal ( (
W =
lit -
fr ) != 0 ?
PC = addr ) |
See: mov W, #lit;
mov W, fr-w;
snb 3.2;
jmp addr |
MOVLW lit; SUBWF fr,0; BTFSC 3,2; GOTO addr |
CJE fr1,fr2,addr |
4 * |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, jump if equal ( (
W =
fr1 -
fr2 ) != 0 ?
PC = addr ) |
See: mov W, fr2;
mov W, fr1-w;
snb 3.2;
jmp addr |
MOVF fr2,0; SUBWF fr1,0; BTFSC 3,2; GOTO addr |
CJNE fr,#lit,addr |
4 * |
C
DC
Z |
W
PC |
fr
lit |
Compare, jump if not equal ( (
W =
lit -
fr ) == 0 ?
PC = addr ) |
See: mov W, #lit;
mov W, fr-w;
sb 3.2;
jmp addr |
MOVLW lit; SUBWF fr,0; BTFSS 3,2; GOTO addr |
CJNE fr1,fr2,addr |
4 * |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, jump if not equal ( (
W =
fr1 -
fr2 ) == 0 ?
PC = addr ) |
See: mov W, fr2;
mov W, fr1-w;
sb 3.2;
jmp addr |
MOVF fr2,0; SUBWF fr1,0; BTFSS 3,2; GOTO addr |
CJA fr,#lit,addr |
4 * |
C
DC
Z |
W
PC |
fr
lit |
Compare, jump if above ( (
W =
lit -
fr ) >= 0 ?
PC = addr ) |
See: mov W, #/lit;
add W, fr;
snb 3.0;
jmp addr |
MOVLW /lit; ADDWF fr,0; BTFSC 3,0; GOTO addr |
CJA fr1,fr2,addr |
4 * |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, jump if above ( (
W =
fr1 -
fr2 ) >= 0 ?
PC = addr ) |
See: mov W, fr1;
mov W, fr2-w;
sb 3.0;
jmp addr |
MOVF fr1,0; SUBWF fr2,0; BTFSS 3,0; GOTO addr |
CJAE fr,#lit,addr |
4 * |
C
DC
Z |
W
PC |
fr
lit |
Compare, jump if above or equal ( (
W =
lit -
fr ) > 0 ?
PC = addr ) |
See: mov W, #lit;
mov W, fr-w;
snb 3.0;
jmp addr |
MOVLW lit; SUBWF fr,0; BTFSC 3,0; GOTO addr |
CJAE fr1,fr2,addr |
4 * |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, jump if above or equal ( (
W =
fr1 -
fr2 ) > 0 ?
PC = addr ) |
See: mov W, fr2;
mov W, fr1-w;
snb 3.0;
jmp addr |
MOVF fr2,0; SUBWF fr1,0; BTFSC 3,0; GOTO addr |
CJB fr,#lit,addr |
4 * |
C
DC
Z |
W
PC |
fr
lit |
Compare, jump if below ( (
W =
lit -
fr ) <= 0 ?
PC = addr ) |
See: mov W, #lit;
mov W, fr-w;
sb 3.0;
jmp addr |
MOVLW lit; SUBWF fr,0; BTFSS 3,0; GOTO addr |
CJB fr1,fr2,addr |
4 * |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, jump if below ( (
W =
fr1 -
fr2 ) <= 0 ?
PC = addr ) |
See: mov W, fr2;
mov W, fr1-w;
sb 3.0;
jmp addr |
MOVF fr2,0; SUBWF fr1,0; BTFSS 3,0; GOTO addr |
CJBE fr,#lit,addr |
4 * |
C
DC
Z |
W
PC |
fr
lit |
Compare, jump if below or equal ( (
W =
lit -
fr ) < 0 ?
PC = addr ) |
See: mov W, #/lit;
add W, fr;
sb 3.0;
jmp addr |
MOVLW /lit; ADDWF fr,0; BTFSS 3,0; GOTO addr |
CJBE fr1,fr2,addr |
4 * |
C
DC
Z |
W
PC |
fr1
fr2 |
Compare, jump if below or equal ( (
W =
fr1 -
fr2 ) < 0 ?
PC = addr ) |
See: mov W, fr1;
mov W, fr2-w;
snb 3.0;
jmp addr |
MOVF fr1,0; SUBWF fr2,0; BTFSC 3,0; GOTO addr |
SB bit |
1 |
- |
PC |
bit |
Skip if bit ( (
fr & ( 1 <<
bit )) == 1 ? PC++ ) |
Users Manual p120 |
BTFSS bit |
SC |
1 |
- |
PC |
C |
Skip if carry (
C ) |
See: sb 3.0 |
BTFSS 3,0 |
SZ |
1 |
- |
PC |
Z |
Skip if zero (
Z ) |
See: sb 3.2 |
BTFSS 3,2 |
SNB bit |
1 |
- |
PC |
bit |
Skip if not bit ( (
fr & ( 1 <<
bit )) == 0 ? PC++ ) |
Users Manual p123 |
BTFSC bit |
SNC |
1 |
- |
PC |
C |
Skip if not carry
( C ) |
See: snb 3.0 |
BTFSC 3,0 |
SNZ |
1 |
- |
PC |
Z |
Skip if not zero
( Z ) |
See: snb 3.2 |
BTFSC 3,2 |
JB bit,addr |
2 * |
- |
PC |
bit |
Jump TO address
if bit ( (
fr & ( 1 <<
bit )) == 1 ?
PC = addr ) |
See: snb bit;
jmp addr |
BTFSC bit; GOTO addr |
JC addr |
2 * |
- |
PC |
C |
Jump TO address
if carry (
C ) |
See: snb 3.0;
jmp addr |
BTFSC 3,0; GOTO addr |
JZ addr |
2 * |
- |
PC |
Z |
Jump TO address
if zero (
Z ) |
See: snb 3.2;
jmp addr |
BTFSC 3,2; GOTO addr |
JNB bit,addr |
2 * |
- |
PC |
bit |
Jump TO address
if not bit ( (
fr & ( 1 <<
bit )) == 0 ?
PC = addr ) |
See: sb bit;
jmp addr |
BTFSS bit; GOTO addr |
JNC addr |
2 * |
- |
PC |
C |
Jump TO address
if not carry (
C ) |
See: sb 3.0;
jmp addr |
BTFSS 3,0; GOTO addr |
JNZ addr |
2 * |
- |
PC |
Z |
Jump TO address
if not zero (
Z ) |
See: sb 3.2;
jmp addr |
BTFSS 3,2; GOTO addr |
unconditional branches |
SKIP |
1 |
- |
PC |
- |
Skip next instruction word ( PC++ ) |
See:
sb 2.0 /snb 2.0 |
BTFSC/BTFSS 2,0 |
JMP addr |
1 * |
- |
PC |
- |
Jump TO (9
bit) address ( PC
= ( page << 9 ) + addr ) |
Users Manual p88 |
GOTO addr |
JMP PC+W |
1 |
C
DC
Z |
PC |
W |
Add W into PC(L),
clear bit 8 (
PC = (
PC &
0xFEFF ) +
W ) |
See: add 2, W |
ADDWF 2,1 |
JMP W |
1 |
- |
PC |
W |
Move W into PC(L),
clear bit 8 (
PC = (
PC &
0xFE00 ) +
W ) |
See: mov 2, W |
MOVWF 2 |
CALL addr |
1 * |
- |
PC |
- |
Call TO address,
clear bit 8 ( STACK[SP++] = PC;
PC = ( page
<< 9 ) + addr ) |
Users Manual p76 |
|
RETW lit,lit... |
1 |
- |
W
PC |
lit |
Return from call, literal
in W (
PC = STACK[SP--];
W =
lit ) |
Users Manual p117 |
|
RET |
1 |
- |
PC |
- |
Return from call (
PC = STACK[SP--]
) |
Users Manual p113 |
|
RETP |
1 |
PA0..2 |
PC |
- |
Return from call, affect PA2 : PA0 (
PC = STACK[SP--];
page = PC
>> 9 ) |
Users Manual p116 |
|
RETI |
1 |
- |
PC
W FSR |
- |
Return from interrupt (
PC = STACK[SP--]
) |
Users Manual p114 |
|
RETIW lit |
1 |
- |
RTCC
PC
W FSR |
lit |
Return from interrupt, compensate
RTCC (
PC = STACK[SP--];
RTCC +=
lit ) |
Users Manual p115 |
|
i/o and control operations |
PAGE addr |
1 |
PA0..2 |
- |
- |
Transfer addr .11:addr .9 into PA2 : PA0 , will delay skipping ( page
= addr >> 9 ) |
Users Manual p112 |
|
BANK fr |
1 |
- |
FSR |
- |
Transfer fr .7:fr .5
into FSR .7:FSR .5 (
FSR = &(
fr ) &
0xE0 ) |
Users Manual p74 |
|
MOV M,#lit |
1 |
- |
M |
lit |
Move literal into
M (
M =
lit ) |
Users Manual p90 |
|
MOV M,W |
1 |
- |
M |
W |
Move W into
M (
M =
W ) |
Users Manual p91 |
|
MOV M,fr |
2 |
Z |
W
M |
fr |
Move fr into
M (
M =
W =
fr ) |
See: mov W, fr;
mov M, W |
|
MOV W,M |
1 |
- |
W |
M |
Move M into
W (
W =
M ) |
Users Manual p104 |
|
MOV fr,M |
2 |
- |
W
fr |
M |
Move M into
fr (
fr =
W =
M ) |
See: mov W, M;
mov fr, W |
|
MOV !port,W |
1 |
- |
!PORT |
W |
Move W into port's
TRIS ( !PORT =
W ) |
Users Manual p93 |
TRIS port (port=5 to 7) |
MOV !port,#lit |
2 |
- |
W
!PORT |
lit |
Move literal into port's
TRIS ( !PORT =
W =
lit ) |
See: mov W, #lit;
mov !port,W |
MOVLW lit; TRIS port (port=5 to 7) |
MOV !port,fr |
2 |
Z |
W
!PORT |
fr |
Move fr into port's
TRIS ( !PORT =
W =
fr ) |
See: mov W, fr;
mov !port,W |
MOVF fr,0; TRIS port (port=5 to 7) |
MOV !OPTION,W |
1 |
- |
!OPTION |
W |
Move W into
!OPTION (
!OPTION =
W ) |
Users Manual p92 |
OPTION |
MOV !OPTION,#lit |
2 |
- |
W
!OPTION |
lit |
Move literal into
!OPTION (
!OPTION =
W =
lit ) |
See: mov W, #lit;
mov !OPTION, W |
MOVLW lit; OPTION |
MOV !OPTION,fr |
2 |
Z |
W
!OPTION |
fr |
Move fr into
!OPTION (
!OPTION =
W =
fr ) |
See: mov W, fr;
mov !OPTION, W |
MOVF fr,0; OPTION |
CLR !WDT |
1 |
TO
PD |
- |
- |
Clear WDT and prescaler (
TO =
PD = 0 ) |
Users Manual p80 |
CLRWDT |
SLEEP |
1 |
TO
PD |
- |
- |
Clear WDT and enter sleep mode (
TO =
PD = 0 ) |
Users Manual p112 |
SLEEP |
IREAD |
1 |
- |
M : W |
M
W |
Read instruction at M
: W into
M :
W (
M :
W =
PROGRAM[M<<8+W] ) |
Users Manual p86 |
|
NOP |
1 |
- |
- |
- |
No operation ( - - ) |
Users Manual p107 |
NOP |