Mitsubishi MELSEC Q Series Programming Manual page 392

Common instruction 1/2
Hide thumbs Also See for MELSEC Q Series:
Table of Contents

Advertisement

BKOR(P)
(2) The constant designated by
S1
+(n 2)
+(n 1)
S1
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and
an error code is stored into SD0.
• The n-bit range from the
• The device range for n points starting from the device designated by
device range for n points starting from the device designated by
device is specified for
• The device range for n points starting from the device designated by
device range for n points starting from the device designated by
device is specified for
Program Example
(1) The following program performs a logical sum operation on the data stored at D100 to D102
and the data stored at R0 to R2 when X20 is turned ON, and stores the operation result into
the area starting from D200.
[Ladder Mode]
[Operation]
D100
D101
D102
7-18
S2
b15
b8
b7
S1
0 0 1 1 1 1 0 0 1 1 0 0 0 0 1 1
S1
+ 1
0 0 0 0 1 0 1 0 1 0 1 0 1 0 1 0
S1
+ 2
1
0
1 0 1
0
1 0 1 0 1
0
1 0 1
0 0 0 0 1 1
1 1
0 0 0 0 1 1
1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1
b15
D
0 0
D
0 0 0 0
+ 1
D
+ 2
1 0 1 0 1 1 1 1 1 1 1 1 1 0 1 0
D
+(n 2)
0 0
+(n 1)
D
1 1 0 0 1 1 1 1
,
S1
and
S1
and
S2
b15
b8
b7
0
0
0
0
1
0
1
0
1
0
1
0
1
0
1
0
0
1
1
0
0
1
1
0
0
1
1
0
0
1
1 1 0 0 0 0 0 0 0 0 1 1 1 1 0 0
b15
D200
0 0 1 1 1 0 1 0 1 0 1 0 1 0 1 0
D201
0 0
1 1 1 1 1 1 1 1 1 1
D202
1 1
0 0
can be between
32768 and 32767 (BIN 16-bit data).
b0
0
b15
n
OR
S2
0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0
1 1
b8
b7
b0
1 1 1 1 1 1 1 1 1 1
0 0 1 1
1 1 1 1 1 1 1 1 1
0
1
0
n
0 0 1 1 1 1
1 1 1 1
1 1
1 1
1 1 1 1
0 0 1 1
, or
device exceeds the range of that device.
S2
D
)
D
)
D
[List Mode]
Step
Instruction
b0
b15
b8
R0
0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0
0
OR
R1
0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0
1
R2
0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1
b8
b7
b0
0 0
1 1
1 1 1 1
0 0 1 1 1 1 1 1
b8 b7
b0
(Error code: 4101)
overlaps with the
S1
. (except when the same
D
(Error code: 4101)
overlaps with the
S2
. (except when the same
D
(Error code: 4101)
Device
b7
b0
D0
3

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Melsec l series

Table of Contents