Individual Instruction Descriptions
4-178
Syntax Description
SUBS A
n
[~], A
n
, {
adrs
} Subtract data memory string from A
n
string, store result in A
n
[~] string
SUBS A
n
[~], A
n
[~],
pma16
Subtract program memory string from A
n
[~] string, store result in A
n
[~] string
SUBS A
n
[~], A
n
, A
n
~ Subtract A
n
~ string from A
n
string, store result in A
n
[~] string
SUBS A
n
[~], A
n
~, A
n
Subtract A
n
string from A
n
~ string, store result in A
n
[~] string
SUBS A
n
[~], A
n
[~], PH Subtract product high (PH) register from A
n
[~] string mode. This instruction ig-
nores the string count, executing only once but maintains the CF and ZF status of
the previous multiply or shift operation as if the sequence was a single string. Word
alignment with PH is maintained, i.e., PH is subtracted from the second word of the
string. Also, only the second word is copied to the destination string.
Example 4.14.81.1 SUBS A0, A0~, *R2++
Subtract data memory string beginning at address in R2 from accumulator string A0~, put result in
accumulator string A0 then increment R2 by 2.
Example 4.14.81.2 SUBS A1~, A1, 0x1220
Subtract program memory string at address 0x1220 from accumulator string A1, put result in
accumulator string A1~.
Example 4.14.81.3 SUBS A2, A2, A2~
Subtract accumulator string A2~ from accumulator string A2, put result in accumulator string A2.
Example 4.14.81.4 SUBS A2, A2~, A2
Subtract accumulator string A2 from accumulator string A2~, put result in accumulator string A2.
Example 4.14.81.5 SUBS A3~, A3~, PH
Subtract PH from accumulator string A3~, put result in accumulator string A3. This instruction ignores
the string count.