Datasheet
1998-2013 Microchip Technology Inc. DS30289C-page 231
PIC17C7XX
XORLW
Exclusive OR Literal with
WREG
Syntax: [ label ] XORLW k
Operands: 0 k 255
Operation: (WREG) .XOR. k WREG)
Status Affected: Z
Encoding:
1011 0100 kkkk kkkk
Description:
The contents of WREG are XOR’ed
with the 8-bit literal 'k'. The result is
placed in WREG.
Words: 1
Cycles: 1
Q Cycle Activity:
Q1 Q2 Q3 Q4
Decode Read
literal 'k'
Process
Data
Write to
WREG
Example:
XORLW 0xAF
Before Instruction
WREG = 0xB5
After Instruction
WREG = 0x1A
XORWF Exclusive OR WREG with f
Syntax: [ label ] XORWF f,d
Operands: 0 f 255
d [0,1]
Operation: (WREG) .XOR. (f) dest)
Status Affected: Z
Encoding:
0000 110d ffff ffff
Description:
Exclusive OR the contents of WREG
with register 'f'. If 'd' is 0, the result is
stored in WREG. If 'd' is 1, the result is
stored back in the register 'f'.
Words: 1
Cycles: 1
Q Cycle Activity:
Q1 Q2 Q3 Q4
Decode Read
register 'f'
Process
Data
Write to
destination
Example:
XORWF REG, 1
Before Instruction
REG = 0xAF 1010 1111
WREG = 0xB5 1011 0101
After Instruction
REG = 0x1A 0001 1010
WREG = 0xB5