C h a p t e r 5 A p p l i e d I n s t r u c t i o n s
5 - 8 3
API
Instruction code
Operand
Function
122
D
EMUL
P
S
1
, S
2
, D
Binary floating-point
multiplication
Device
X
Y
M
S
K
16#
F
KnM KnS
D
W
T
C
V
Z
S
1
S
2
D
Pulse instruction 16-bit instruction 32-bit instruction (9 steps)
–
E xp la nat io n
The binary floating-point value in
S
1
is multiplied by the binary
floating-point value in
S
2
, and the product is stored in
D
.
S
1
: Multiplicand;
S
2
: Multiplier;
D
: Product
If
S
1
is a floating-point value, the instruction will be used to multiply the
floating-point value by the binary floating-point value in
S
2
. If
S
2
is a
floating-point value, the instruction will be used to multiply the binary
floating-point value in
S
1
by the floating-point value.
S
1
and
S
2
can be the same register. If the instruction DEMUL is used
under the circumstances, the value in the register is multiplied by itself
whenever the conditional contact is ON in a scan cycle. Generally, the
pulse instruction DEMULP is used.
If the absolute value of an oepration result is greater than the maximum
floating-point value available, a carry flag will be ON.
If the absolute value of an oepration reuslt is less than the minimum
floating-point value available, a borrow flag will be ON.
If an operation result is 0, a zero flag will be ON.
SM1064 is the zero flag in an Ox motion subroutine, and SM968 is the
zero flag in O100.
SM1065 is the borrow flag in an Ox motion subroutine, and SM969 is the
borrow flag in O100.
SM1066 is the carry flag in an Ox motion subroutine, and SM970 is the
carry flag in O100.
E xamp le 1
When X0.1 is ON, the binary floating-point value in (D1, D0) is multiplied
by the binary floating-point value in (D11, D10), and the product is stored
in (D21, D20).
X0.1
DEMUL
D0
D10
D20
E xamp le 2
When X0.2 is ON, F1234.0 is multiplied by the binary floating-point value
in (D1, D0), and the product is stored in (D11, D10).
X0.2
DEMUL
D0
F1234. 0
D10
A dditio nal
re m ark
Please refer to section 5.3 for more information about performing
operations on floating-point numbers.
Summary of Contents for AH500
Page 9: ...viii...
Page 53: ...AH500 Motion Control Module Manual Wiring AH10PM 5A and a Yaskawa servo drive 2 32...
Page 55: ...AH500 Motion Control Module Manual Wiring AH10PM 5A and a Fuji servo drive 2 34...
Page 115: ...AH500 Motion Control Module Manual 4 16 MEMO...
Page 375: ...AH500 Motion Control Module Manual 5 260 MEMO...
Page 383: ...AH500 Motion Control Module Manual 6 8 MEMO...
Page 419: ...AH500 Motion Control Module Manual 7 36 MEMO...
Page 436: ...Chapter 8 Electronic Cam 8 17...
Page 483: ...AH500 Motion Control Module Manual 10 8 MEMO...
Page 505: ...AH500 Motion Control Module Manual 12 8 MEMO...
Page 515: ...AH500 Motion Control Module Manual 13 10 MEMO...
Page 544: ...Appendix A Error Code Table Table of Contents A 1 Error Code Table A 2 A 1...