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.
[the_ad id=”3059″]Syntax:
[ label ] ADDLW k
Operation:
(W) + k → (W)
Operands:
- k is from 0 to 255 (decimal)
Status Affected: C, DC, Z
Example:
1 |
ADDLW 0x05 |
1 |
W = 0x01 |
1 |
W = 0x06 |
Example:
1 |
ADDLW .127 |
1 |
W = 0x01 |
1 |
W = 0x80 |