PIC16CXX Instruction Set


SUBWF


Syntax : SUBWF f,d

Description : Subtracts (2's complement method) the W register from 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'.

Function : (f) - (W) → d

Hex code : 02ff

Bit field:
00 0010 dfff ffff

Words : 1

Cycles : 1

Affected flags : Zero, Carry, Digit Carry

See also :   ADDWF
Previous    Upper level    Next