3 . I n s t r u c t i o n S e t
M N 0 5 0 0 3 0 0 3 E F or m o r e i nf o r m a t i o n v i s i t : www. e a t o n. c o m
3-423
API Mnemonic
Operands
Function
175
D DIVR P
S
1
, S
2
, D
Floating Point Number Division
Bit Devices
Word devices
Program Steps
Type
OP
X Y M S K H KnX KnY KnM KnS T
C D E
F
S
1
*
S
2
*
D
*
DDIVR: 13 steps
ELC ELCB
ELCM
PB PC/PA/PH
PV
PB PH/PA
32 16
P
32 16
P
32 16
P 32 16 P 32 16
P
Operands:
S
1
:
Floating point number
dividend
S
2
:
Floating point number divisor
D:
Quotient
Description:
1. S
1
and S
2
are Floating point numbers
2. ELC-PB, ELCB-PB series models do not support index register E and F.
3. The DDIVR operands, S
1
and S
2
can each be 2 consecutive D-register addresses or actual
floating point values (e.g. F1.2).
4. When
S
1
and S
2
use D registers, the function will be the same as
API
123 EDIV.
5.
If
S
2
= 0, this is a bad operation”, DDIVR will not execute, M1067, M1068=On, and D1067
records the error code H’0E19.
6. If the absolute value of the operation result
> the
maximum floating point numbers, the carry flag
M1022=On.
7. If the absolute value of operation result < the minimum floating point numbers, the borrow flag
M1021=On.
8. If the operation result equals 0, the zero flag M1020=On.
Program example 1:
When X0 = ON, divide floating point number F1.200E+0 (enter F1.2, scientific notation F1.200E+0
will be displayed in the instruction) by F2.200E+0 and store the result F0.545E+0 in D10 and D11.
X0
DDIVR
F1.200E+0
D10
F2.200E+0
Program example 2:
When X1=On, divide the floating point number value (D1, D0)
by (D11, D10) and store the quotient
into registers assigned by (D21, D20).
X1
DDIVR
D0
D10
D20
Summary of Contents for ELC-PB
Page 1: ......
Page 5: ...For more information visit www eaton com MN05003003E iv...
Page 29: ...ELC Programming Manual For more information visit www eaton com MN05003003E 1 24 MEMO...
Page 502: ...3 Instruction Set MN05003003E For more information visit www eaton com 3 333...
Page 601: ...ELC Programming Manual For more information visit www eaton com MN05003003E 3 432...
Page 625: ...ELC Programming Manual For more information visit www eaton com MN05003003E 3 456...