Comparison Operation; Block Data Comparison (=) - Mitsubishi MELSEC-q Programming Manual

Melsec q series; melsec l series
Hide thumbs Also See for MELSEC-q:
Table of Contents

Advertisement

5 MELSEC FUNCTIONS

5.4 Comparison Operation

5.4.1 Block data comparison (=)

n points of BIN 16-bit data (word unit), starting at the specified devices, are compared in terms of "=".
Function definition
5.4.2 Block data comparison (<>)
n points of BIN 16-bit data (word unit), starting at the specified devices, are compared in terms of "<>".
Function definition
5 - 10
BKCMP_EQ_M
BOOL BKCMP_EQ_M (BOOL EN, ANY16 S1, ANY16 S2, ANY16 n, BOOL D);
Argument Name
EN
S1
S2
n
D
Return Value
BOOL
Execution condition
Example of use
(* When execution condition X0 turns ON, the data of the number of points stored *)
(* in D0, starting at D100, is compared with the data of the number of points stored *)
(* in D0, starting at D200, in terms of "=", and the result stored into M0 and later.
BKCMP_EQ_M (X0, D100, D200, D0, M0);
Corresponding MELSEC command
BKCMP= (BIN block data comparison (=))
BKCMP_NE_M
BOOL BKCMP_NE_M (BOOL EN, ANY16 S1, ANY16 S2, ANY16 n, BOOL D);
Argument Name
EN
S1
S2
n
D
Return Value
BOOL
Execution condition
Example of use
(* When execution condition X0 turns ON, the data of the number of points stored in *)
(* D0, starting at D100, is compared with the data of the number of points stored
(* D0, starting at D200, in terms of "<>", and the result is stored into M0 and later. *)
BKCMP_NE_M (X0, D100, D200, D0 M0);
Corresponding MELSEC command
BKCMP<> (BIN block data comparison (<>))
IN/OUT
Execution condition (Function is executed only when the
IN
result is TRUE)
Compared data (BIN 16-bit data)
IN
Comparison data (BIN 16-bit data)
IN
Number of data to be compared (BIN 16-bit data)
IN
Comparison
OUT
result (bit)
IN/OUT
Execution condition (Function is executed only when the
IN
result is TRUE)
Compared data (BIN 16-bit data)
IN
Comparison data (BIN 16-bit data)
IN
Number of data to be compared (BIN 16-bit data)
IN
Comparison
OUT
result (bit)
For the usable data type, refer to "3.2.2
About ANY type".
Description
When comparison
Comparison
condition is satisfied
When comparison
result
condition is not satisfied OFF
Description
Description
When comparison
Comparison
condition is satisfied
When comparison
result
condition is not satisfied OFF
Description
ON
*)
ON
*)
5 - 10

Advertisement

Table of Contents
loading

This manual is also suitable for:

Melsec-l

Table of Contents