Mitsubishi MELSEC-Q series Programming Manual page 167

Process control instructions
Hide thumbs Also See for MELSEC-Q series:
Table of Contents

Advertisement

Set Data
Set Data
(1) Data specified in S.AVE instruction
Specified position
Symbol
n
+0
S1
+1
E1
+2
Input
+3
E2
data
+4
+2
n-1
E
n
+2n
Block
+0
D1
BW
memory
+1
*1
The data of the item(s) where the values within the recommended range are given in the parentheses are stored by the
system. Users cannot set the data.
Set Data
Processing contents
(1) Calculation of average value
The average value of the input value 1 (E1) to n (En) is calculated.
As the denominator (N), the value specified as the number of inputs (n) is used.
E1
E2
E3
BW
N
Operation Error
In the following cases, the error flag (SM0) turns ON and the error code is stored in SD0.
Error code
When an operation error occurs
When the value of
4100
normalized number
When not 1  number of inputs (n)  16
When the value of
4140
normalized number
4141
When an operation error occurs
Name
Recommended range
Input count
1 to 16
Input value 1
Input value 2
-999999 to 999999
Input value n
Output value
(Average value of E1 to En)
E
n
Error definition
is either a non-numeric or non-
S1
is either a non-numeric or non-
S1
*1
Unit Data format
BIN
––
16bit
Real
––
number
Real
––
number
QnPHCPU
QnPRHCPU
––
––
––
––
S.AVE
9
Standard
Set
value
by
2
––
U
3
––
U
4
4
––
S
6
7
8
QnUDPVCPU
––
––
165

Advertisement

Table of Contents
loading

Table of Contents