NAiS FP1 Hardware Manual page 174

Fp series programmable controller
Table of Contents

Advertisement

6-3. Description of High-level Instructions
Description
166
• The 16-bit data or 16-bit equivalent constant specified by S1 and S2 are added together when
the trigger turns ON. The added result is stored in D.
Augend data
S1
Flag condition
• Error flag (R9007):
Turns ON and keeps the ON state when the area specified using the index
modifier exceeds the limit. The error address is transferred to DT9017
and held. (See notes below.)
• Error flag (R9008):
Turns ON for an instant when the area specified using the index modifier
exceeds the limit. The error address is transferred to DT9018. (See notes
below.)
• = flag (R900B):
Turns ON for an instant when the calculated result is recognized as "0".
• Carry flag (R9009):
Turns ON for an instant when the calculated result exceeds the range of
16-bit data (overflows or underflows).
*Range of 16-bit data: K-32768 to K32767 (H8000 to H7FFF)
Notes:
• Special data registers DT9017 and DT9018 are available only for FP1s with CPU
version 2.7 or later. (All FP1s with a suffix "B" on the part number have this function.)
• When using special internal relays R9008, R9009, and R900B as the flags for this
instruction, be sure to program the flags at the address immediately after the
instruction.
• Refer to page 223, "8-3. Table of Special Internal Relays", for details about error
flags, = flag, and carry flag.
• If the calculated result accidently overflows or underflows (if special internal relay
R9009 turns ON), use of the
recommended. When you use the
to convert the 16-bit addend and augend into 32-bit data using the
instruction.
Addend data
Trigger turns ON
+
S2
F23 (D+)
instruction (32-bit data addition) is
F23 (D+)
instruction instead of
Result
D
F22 (+)
, be sure
F89 (EXT)

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents