Add Literal and W
The contents of the W register are added to the eight-bit literal ‘k’ and the result is placed in the W register.
Syntax:
[ label ] ADDLW k
Operation:
(W) + k → (W)
Operands:
- k is from 0 to 255 (decimal)
Status Affected: C, DC, Z
Example:
ADDLW 0x05
Before instruction:
W = 0x01
After instruction:
W = 0x06
Example:
ADDLW .127
Before instruction:
W = 0x01
After instruction:
W = 0x80