Download Print this page

Dividing 16-Bit Binary Data - Mitsubishi Electric MELSEC iQ-F FX5 Programming Manual

Instructions, standard functions/function blocks
Hide thumbs Also See for MELSEC iQ-F FX5:

Advertisement

Dividing 16-bit binary data

/(P)(_U) instruction and DIV(P)(_U) instruction can be used for division of 16-bit binary data.
/(P)(_U)
These instructions divide the 16-bit binary data in the device specified by (s1) by the 16-bit binary data in the device specified
by (s2), and store the result in the device specified by (d).
Ladder diagram
(s1)
(s2)
(d)
FBD/LD
EN
ENO
s1
d
s2
("DIVISON", "DIVISIONP", "DIVISION_U", "DIVISIONP_U" enters .)
*1 Supported by engineering tool version "1.035M" and later.
Setting data
■Descriptions, ranges, and data types
Operand
Description
(s1)
/(P)
Dividend data or the device where the data to
be divided by another is stored
/(P)_U
(s2)
/(P)
Divisor data or the device where the data by
which another is to be divided is stored
/(P)_U
(d)
/(P)
Head device for storing the operation result
/(P)_U
EN
Execution condition
ENO
Execution result
■Applicable devices
Operand
Bit
X, Y, M, L, SM,
F, B, SB, S
(s1)
(s2)
(d)
Word
T, ST, C, D, W,
U\G
SD, SW, R
*1
Structured text
ENO:=DIVISION(EN,s1,s2,d);
ENO:=DIVISIONP(EN,s1,s2,d);
Range
Data type
-32768 to +32767
16-bit signed binary
0 to 65535
16-bit unsigned binary
-32768 to +32767
16-bit signed binary
0 to 65535
16-bit unsigned binary
32-bit signed binary
32-bit unsigned binary
Bit
Bit
Double word Indirect
specification
Z
LC
LZ
7.2 Arithmetic Operation Instructions
ENO:=DIVISION_U(EN,s1,s2,d);
ENO:=DIVISIONP_U(EN,s1,s2,d);
Data type (label)
ANY16_S
ANY16_U
ANY16_S
ANY16_U
ANY16_S_ARRAY
(Number of elements:
2)
ANY16_U_ARRAY
(Number of elements:
2)
BOOL
BOOL
Constant
Others
K, H
E
$
7 BASIC INSTRUCTIONS
209
7

Hide quick links:

Advertisement

loading