6-102
6.3 Data Conversion Instructions
6.3.15 4-digit BCD block data to 16-bit BIN block data conversion
BKBIN
Program
E
xam
pl
e
In the following program, the BCD values in D100 to D102 are converted to the BIN values when
X20 turns ON, and the results are stored to D200 and the following devices.
[Structured ladder]
[ST]
Var_D0:=3;
BKBINP(X20,D100,Var_D0,D200);
[Operation]
B
IN
convers
i
on
(
wh
en
Var
_
D0
=
3)
0 0 0
1 1 1 1 1 1
0 0
1
0 0 0 0
0 0 0
1 1 1
0
1 1 1 1
0 0
1 1
0
0 0
1
0 0
1 1 1
0 0 0 0
1 1 1 1
1
0 0 0 0 0 0 0
1
0 0 0 0 0 0 0
0
1 1 1
0
1 1
0 0
1
0
1
0
1
0 0
1
0 0
1 1
0 0
1 1
0 0
1 1
0 0
1
D
2
00
B
IN
8080
D
2
0
2
B
IN
9999
D
2
0
1
B
IN
7
654
D
1
00
BCD
8080
D
1
0
2
BCD
9999
D
1
0
1
BCD
7
654
8
1
9
2
4
09
6
2
0
4
8
1
0
24
512 256 12
8
64
3
2
16
8
4 2 1
2
000
1
000
800
4
00
2
00
1
00
80
4
0
2
0
1
0
8
4 2 1
4
000
8000
Summary of Contents for MELSEC Q Series
Page 1: ...Structured Programming Manual Mitsubishi Programmable Controller QCPU Common Instructions ...
Page 2: ......
Page 14: ...A 12 MEMO ...
Page 340: ...6 178 MEMO MTR ...
Page 708: ...7 368 MEMO ...
Page 776: ...8 68 MEMO ...
Page 796: ...9 20 MEMO ...
Page 804: ...App 8 MEMO ...
Page 812: ...Index 8 MEMO ...
Page 815: ......