[Menu]>[Guide to use the PIC]


Instruction spec (6) of PIC16 series


Instruction set


MOVFMove f
Form [label]MOVFf, d
( label is omitable, shows SPACE code )
Operands f : Register file addesss ( 00(00h) to 127(7Fh) )
d : Destination select ( 0 or 1 )
Operation It moves (copy) the contents of the f register.
d = 0 : store result in W
d = 1 : store result in f

Seemed to move from the f register to the f register no meaning, but its being used in the purpose to set a flag.
Flag When the result is 0, it sets 1 to the Z flag.
When the result is not 0, it sets 0 to the Z flag.
Instruction
cycles
1 cycle




MOVLWMove literal to W
Form [label]MOVLWk
( label is omitable, shows SPACE code )
Operandsk : literal field ( 00(00h) to 255(FFh) )
OperationIt sets literal data to the W register.
OperationNo change
Instruction
cycles
1 cycle




MOVWFMove W to f
Form [label]MOVWFf
( label is omitable, shows SPACE code )
Operandsf : Register file addesss ( 00(00h) to 127(7Fh) )
OperationIt moves (copy) the contents of the W register to the f register.
FlagNo change
Instruction
cycles
1 cycle


NOPNo Operation
Form [label]NOP
( label is omitable, shows SPACE code )
OperandsNone
Operation It is moved to the next instruction without processing anything.

This instruction is used when it adjusts a processing time as the timer processing, and so on.
FlagNo change
Instruction
cycles
1 cycle


Next instructions