EasyManuals Logo
Home>IDEC>Controller>FC4A-C24R2

IDEC FC4A-C24R2 User Manual

IDEC FC4A-C24R2
525 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #233 background imageLoading...
Page #233 background image
« FC4A MICROSMART USERS MANUAL » 11-1
11: BINARY ARITHMETIC INSTRUCTIONS
Introduction
The binary arithmetic instructions make it possible for the user to program computations using addition, subtraction, mul-
tiplication, and division. For addition and subtraction operands, internal relay M8003 is used to carry or to borrow.
The ROOT instruction can be used to calculate the square root of the value stored in a data register.
ADD (Addition)
SUB (Subtraction)
MUL (Multiplication)
DIV (Division)
Applicable CPU Modules
FC4A-C10R2/C FC4A-C16R2/C FC4A-C24R2/C FC4A-D20K3/S3 FC4A-D20RK1/RS1 & FC4A-D40K3/S3
XXX X X
S1 + S2 D1, CY
When input is on, 16-bit data designated by source operands S1
and S2 are added. The result is set to destination operand D1
and carry (M8003).
REP
**
S1(R)
*****
D1(R)
*****
ADD(*) S2(R)
*****
S1 – S2 D1, BW
When input is on, 16-bit data designated by source operand S2
is subtracted from 16-bit data designated by source operand S1.
The result is set to destination operand D1 and borrow (M8003).
REP
**
S1(R)
*****
D1(R)
*****
SUB(*) S2(R)
*****
S1 × S2
D1·D1+1
When input is on, 16-bit data designated by source operand S1
is multiplied by 16-bit data designated by source operand S2.
The result is set to 32-bit data designated by destination oper-
and D1.
REP
**
S1(R)
*****
D1(R)
*****
MUL(*) S2(R)
*****
S1 ÷ S2 D1 (quotient), D1+1 (remainder)
When input is on, 16-bit data designated by source operand S1
is divided by 16-bit data designated by source operand S2. The
quotient is set to 16-bit destination operand D1, and the remain-
der is set to the next 16-bit data.
When S2 is 0 (dividing by 0), the ERR LED and special internal
relay M8004 (user program execution error) are turned on.
A user program execution error also occurs in the following divi-
sion operation.
Data type I: –32768 ÷ (–1)
REP
**
S1(R)
*****
D1(R)
*****
DIV(*) S2(R)
*****

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the IDEC FC4A-C24R2 and is the answer not in the manual?

IDEC FC4A-C24R2 Specifications

General IconGeneral
BrandIDEC
ModelFC4A-C24R2
CategoryController
LanguageEnglish

Related product manuals