232
6 BASIC INSTRUCTIONS
6.2 Arithmetic Operation Instructions
BCD 4-digit addition and subtraction operations
B+(P), B-(P) [When two data are set]
■B+
• Adds the BCD 4-digit data designated by (D) and the BCD 4-digit data designated by (S), and stores the result of the
addition at the device designated by (D).
• 0 to 9999 (BCD 4 digits) can be assigned to (S) and (D).
• If the result of the addition operation exceeds 9999, the higher bits are ignored. The carry flag (SM700) in this case does
not turn ON.
■B-
• Subtracts the BCD 4-digit data designated by (S) and the BCD 4-digit data designated by (D), and stores the result of the
subtraction at the device designated by (D).
• 0 to 9999 (BCD 4 digits) can be assigned to (S) and (D).
• The following will result if an underflow is generated by the subtraction operation: The carry flag (SM700) in this case does
not turn ON.
(S): Data for adding/subtracting or head number of the devices where the data for adding/subtracting is stored (BCD 4 digits)
(D): Head number of the devices where the data to be added to/subtracted from is stored (BCD 4 digits)
Setting
data
Internal device R, ZR J\ U\G Zn Constant
K, H
Others
Bit Word Bit Word
(S)
(D)
Basic
Process
High
performance
Redundant
Universal
LCPU
Command
Command
P
B+/B
B+, B
B+P, B
P
S D
S D
indicates an instruction symbol of .
Digits exceeding the designated
number of digits are assumed to be 0.
40 4420346078
D D
S