SUBB subtract the value of operand from the value of the Accumulator, leaving the resulting value in the Accumulator. The value operand is not affected. If a borrow was required for bit 7, otherwise it is cleared. In other words, if the unsigned value being subtracted is greater than the Accumulator the Carry Flag is set. If a borrow was required for bit 3, otherwise it is cleared. In other words, the bit is set if the low nibble of the value being subtracted was greater than the low nibble of the Accumulator. If a borrow was required for bit 6 or for bit 7, but not both. In other words, the subtraction of two signed bytes resulted in a value outside the range of a signed byte (-128 to 127). Otherwise it is cleared.
Syntax : SUBB A,operand
Example : SUBB A,R0
In this the content in the register R0 will be subtracted from content in accumulator. The result will be stored in Accumulator.
Syntax : SUBB A,operand
Example : SUBB A,R0
In this the content in the register R0 will be subtracted from content in accumulator. The result will be stored in Accumulator.
- Instruction
- Opcode
- Bytes
- Flags
- SUBB A,#data
- 0x94
- 2
- C,AC,OV
- SUBB A,iram_addr
- 0x95
- 2
- C,AC,OV
- SUBB A,@R0
- 0x96
- 1
- C,AC,OV
- SUBB A,@R1
- 0x97
- 1
- C,AC,OV
- SUBB A,R0
- 0x98
- 1
- C,AC,OV
- SUBB A,R1
- 0x99
- 1
- C,AC,OV
- SUBB A,R2
- 0x9A
- 1
- C,AC,OV
- SUBB A,R3
- 0x9B
- 1
- C,AC,OV
- SUBB A,R4
- 0x9C
- 1
- C,AC,OV
- SUBB A,R5
- 0x9D
- 1
- C,AC,OV
- SUBB A,R6
- 0x9E
- 1
- C,AC,OV
- SUBB A,R7
- 0x9F
- 1
- C,AC,OV