Mitsubishi MELSEC-Q/L Programming Manual page 254

Table of Contents

Advertisement

BKBIN, BKBINP
Function
(1) Converts BCD data (0 to 9999) n points from device designated by
designated by
.
D
BCD 1234
0
0 0 1 0 0 1 0 0 0 1 1 0 1 0 0
S
S
+1
BCD 5678
0
1 0 1 0 1 1 0 0 1 1 1 1 0 0 0
S
+2
BCD 1545
0
0 0 1 0 1 0 1 0 1 0 0 0 1 0 1
+(n 2)
S
BCD 4321
0
1 0 0 0 0 1 1 0 0 1 0 0 0 0 1
+(n 1)
BCD 5555
0
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
S
D
0
0 0 0 0 1 0 0 1 1 0 1 0 0 1 0
BIN 1234
D
+1
BIN 5678
0
0 0 1 0 1 1 0 0 0 1 0 1 1 1 0
D
+2
BIN 1545
0
0 0 0 0 1 1 0 0 0 0 0 1 0 0 1
D
+(n 2)
0
0 0 1 0 0 0 0 1 1 1 0 0 0 0 1
BIN 4321
D
+(n 1)
BIN 5555
0
0 0 1 0 1 0 1 1 0 1 1 0 0 1 1
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.
Error
code
The nth data from the device specified by
4100
range.
The points specified in n exceed those of the corresponding device
4101
specified in
or
.
S
D
The same device is specified in
Program Example
(1) The following program converts, when X20 is turned ON, the BCD data stored at D100 to D102 to BIN and stores the
operation result into the area starting from D200.
[Ladder Mode]
252
n
BIN conversion
n
Error details
is outside the 0 to 9999
S
and
.
S
D
[List Mode]
Step
to BIN, and stores result following the device
S
Q00J/
Q00/
QnH
Q01
Device
Instruction
QnPH QnPRH
QnU
LCPU

Advertisement

Table of Contents
loading

Table of Contents