Calculating the mean value of 32-bit binary data
DMEAN(P)(_U)
RnPCPU
RnCPU RnENCPU
(Process)
These instructions calculate the average value of the (n) points of 32-bit data in the devices starting from the specified one.
Ladder
(s)
FBD/LD
EN
ENO
s
d
n
■Execution condition
Instruction
DMEAN
DMEAN_U
DMEANP
DMEANP_U
Setting data
■Descriptions, ranges, and data types
Operand
(s)
DMEAN(P)
DMEAN(P)_U
(d)
DMEAN(P)
DMEAN(P)_U
(n)
EN
ENO
*1 When specifying setting data by using a label, define an array to secure enough operation area and specify an element of the array
label.
■Applicable devices
Operand
Bit
X, Y, M, L,
SM, F, B, SB,
FX, FY
(s)
(d)
(n)
7 APPLICATION INSTRUCTIONS
940
7.20 Data Processing Instructions
RnPCPU
RnSFCPU RnSFCPU
(Redundant)
(Standard)
(Safety)
(d)
(n)
Execution condition
Description
Start device where the data for calculating the
average value are stored
Start device for storing the average value
Number of data, or the device number where the
number of data is stored
Execution condition
Execution result
Word
J\
T, ST, C, D, W,
SD, SW, FD, R,
ZR, RD
ST
ENO:=DMEAN(EN,s,n,d);
ENO:=DMEANP(EN,s,n,d);
Range
0 to 65535
Double word Indirect
U\G, J\,
Z
LT, LST,
U3E\(H)G
LC
ENO:=DMEAN_U(EN,s,n,d);
ENO:=DMEANP_U(EN,s,n,d);
Data type
Data type (label)
32-bit signed binary
ANY32_S
32-bit unsigned binary
ANY32_U
32-bit signed binary
ANY32_S
32-bit unsigned binary
ANY32_U
16-bit unsigned binary
ANY16
Bit
BOOL
Bit
BOOL
Constant
specification
LZ
K, H E
*1
*1
Others
$