English
Language : 

PIC17C7XX Datasheet, PDF (222/328 Pages) Microchip Technology – High-Performance 8-Bit CMOS EPROM Microcontrollers with 10-bit A/D
PIC17C7XX
RRNCF
Syntax:
Operands:
Operation:
Status Affected:
Encoding:
Description:
Rotate Right f (no carry)
[ label ] RRNCF f,d
0 ≤ f ≤ 255
d ∈ [0,1]
f<n> → d<n-1>;
f<0> → d<7>
None
0010 000d ffff ffff
The contents of register 'f' are rotated
one bit to the right. If 'd' is 0 the result is
placed in WREG. If 'd' is 1 the result is
placed back in register 'f'.
register f
Words:
1
Cycles:
1
Q Cycle Activity:
Q1
Decode
Q2
Read
register 'f'
Q3
Process
Data
Q4
Write to
destination
Example 1:
RRNCF REG, 1
Before Instruction
WREG = ?
REG = 1101 0111
After Instruction
WREG = 0
REG = 1110 1011
Example 2:
RRNCF REG, 0
Before Instruction
WREG = ?
REG = 1101 0111
After Instruction
WREG = 1110 1011
REG = 1101 0111
SETF
Set f
Syntax:
[ label ] SETF f,s
Operands:
0 ≤ f ≤ 255
s ∈ [0,1]
Operation:
FFh → f;
FFh → d
Status Affected: None
Encoding:
0010 101s ffff ffff
Description:
If 's' is 0, both the data memory location
'f' and WREG are set to FFh. If 's' is 1
only the data memory location 'f' is set
to FFh.
Words:
1
Cycles:
1
Q Cycle Activity:
Q1
Decode
Q2
Read
register 'f'
Q3
Process
Data
Q4
Write
register 'f'
and other
specified
register
Example1:
SETF REG, 0
Before Instruction
REG = 0xDA
WREG = 0x05
After Instruction
REG = 0xFF
WREG = 0xFF
Example2:
SETF REG, 1
Before Instruction
REG = 0xDA
WREG = 0x05
After Instruction
REG = 0xFF
WREG = 0x05
DS30289A-page 222
© 1998 Microchip Technology Inc.