16F876 Microchip Technology, 16F876 Datasheet - Page 144

no-image

16F876

Manufacturer Part Number
16F876
Description
28/40-pin 8-Bit CMOS FLASH Microcontrollers
Manufacturer
Microchip Technology
Datasheet
PIC16F87X
SUBLW
Syntax:
Operands:
Operation:
Status Affected: C, DC, Z
Description:
SUBWF
Syntax:
Operands:
Operation:
Status Affected: C, DC, Z
Description:
SWAPF
Syntax:
Operands:
Operation:
Status Affected:
Description:
DS30292B-page 144
Subtract W from f
[ label ]
0
d
(f) - (W)
Subtract (2’s complement method)
W register from register 'f'. If 'd' is 0,
the result is stored in the W regis-
ter. If 'd' is 1, the result is stored
back in register 'f'.
Subtract W from Literal
[ label ]
0
k - (W)
The W register is subtracted (2’s
complement method) from the
eight bit literal 'k'. The result is
placed in the W register.
Swap Nibbles in f
[ label ] SWAPF f,d
0
d
(f<3:0>)
(f<7:4>)
None
The upper and lower nibbles of
register 'f' are exchanged. If 'd' is
0, the result is placed in W regis-
ter. If 'd' is 1, the result is placed in
register 'f'.
f
k
[0,1]
f
[0,1]
127
255
127
SUBWF f,d
SUBLW k
W)
destination)
(destination<7:4>),
(destination<3:0>)
XORLW
Syntax:
Operands:
Operation:
Status Affected:
Description:
XORWF
Syntax:
Operands:
Operation:
Status Affected:
Description:
Exclusive OR W with f
[ label ]
0
d
(W) .XOR. (f)
Z
Exclusive OR the contents of the
W register with register 'f'. If 'd' is
0, the result is stored in the W
register. If 'd' is 1, the result is
stored back in register 'f'.
Exclusive OR Literal with W
[ label ]
0
(W) .XOR. k
Z
The contents of the W register
are XOR’ed with the eight bit lit-
eral 'k'. The result is placed in
the W register.
f
[0,1]
k
127
1999 Microchip Technology Inc.
255
XORWF
XORLW k
destination)
W)
f,d

Related parts for 16F876