5- 103 5- 103
5 MELSEC FUNCTIONS
5.19.5 Bit zone control ZONE_MD
The output value is zone-controlled with a bias value added to the specified BIN 16-bit data.
Function definition
BOOL ZONE_MD (BOOL EN, ANY16 S1, ANY16 S2, ANY16 S3, ANY16 D);
Argument Name
IN/OUT
Description
EN IN
Execution condition (Function is executed only when the
result is TRUE)
S1 IN
Negative bias value added to input value (BIN 16-bit
data)
S2
IN
Positive bias value added to input value (BIN 16-bit data)
S3
IN
Input value (BIN 16-bit data)
D
OUT
Output value (BIN 16-bit data)
Remarks: The output value is controlled as described below.
When S3 (input value) < 0
......................S3 (input value) + S1 (negative bias value) D (output value)
When S3 (input value) = 0 ...............................................0 D (output value)
When S3 (input value) > 0
....................... S3 (input value) + S1 (positive bias value) D (output value)
Return Value
Description
BOOL Execution
condition
Example of use
(* When execution condition X0 turns ON, the bias value specified in iData1 or *)
(* iData2 is added to the input value specified in iData3, and the result is stored *)
(* into Result.
*)
ZONE_MD (X0, iData1, iData2, iData3, Result);
Corresponding MELSEC command
ZONE (16-bit zone control)
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: ......