[Menu]>[Guide to use the PIC]


Instruction spec (3) of PIC16 series



Instruction set


CALLCall subroutine
Form [label]CALLk
( label is omitable, shows SPACE code )
Operandsk : literal field ( 000(000h) to 2047(7FFh) )
Operation It jumps to the subroutine which the literal field shows.
It sets the literal value to 11 bits of lower part of program counter (PC) and it sets the bit 3 and 4 of the PCLATH register to 2 bits of higher part.
It stores the present PC value +1 in the stack.
FlagNo change
Instruction
cycles
2 cycles




CLRFClear f
Form [label]CLRFf
( label is omitable, shows SPACE code )
Operandsf : Register file addesss ( 00(00h) to 127(7Fh) )
Operation It clears f register and it sets Z flag.

00000000 f register
1 Z flag
FlagIt sets 1 to the Z flag.
Instruction
cycles
1 cycle


CLRWClear W
Form [label]CLRW
( label is omitable, shows SPACE code )
OperandsNone
Operation It clears W register and it sets Z flag.

00000000 W register
1 Z flag
FlagIt sets 1 to the Z flag.
Instruction
cycles
1 cycle


CLRWDTClear Watchdog Timer
Form [label]CLRWDT
( label is omitable, shows SPACE code )
OperandsNone
Operation It resets a watchdog timer.
When using the prescaler for the watchdog timer, it resets the prescaler, too.
FlagIt sets 1 to TO and the PD.
Instruction
cycles
1 cycle


Next instructions