6 - 31 6 - 31
6 IEC FUNCTIONS
6.5 Arithmetic Operation Functions
6.5.1 Addition ADD_E
The specified multiple data are added.
Function definition
BOOL ADD_E( BOOL EN, ANY_NUM S1, ANY_NUM S2,....,ANY_NUM Sn,
ANY_NUM D1 );
Argument
Argument Name
IN/OUT
Description
EN
IN
Execution condition (Function is executed only when the result is TRUE)
S1 to Sn
IN
Data to be added
D1
OUT
Addition operation result
Return value
Return Value
Description
BOOL
Execution condition (bit data)
Example of use
Argument Type
ST Program
Conversion Result
Used Instruction
REAL
b_result := ADD_E( b_select,
r_data1, r_data2, r_data3 );
LD b_select
E+ r_data1
r_data2
r_data3
LD b_select
OUT b_result
LD, E+, OUT
INT
b_result := ADD_E( b_select,
D10, D20, D30, D40 );
LD b_select
+ D10
D20
D40
+ D30
D40
LD b_select
OUT b_result
LD, +, OUT
DINT
b_result := ADD_E( b_select,
di_data1,
di_data2, di_data3 );
LD b_select
D+
di_data1
di_data2
di_data3
LD b_select
OUT b_result
LD,D+,OUT
For the usable data type, refer to "3.2.2 About ANY type".
Содержание MELSEC L series
Страница 1: ...Programming Manual Structured Text ...
Страница 2: ......
Страница 73: ...4 33 4 33 4 ST PROGRAM EXPRESSIONS MEMO ...
Страница 297: ......