Conversion From Bcd To Bin (16 Bits, 32Bits): Bin, Dbin - Mitsubishi Electric MELSEC Q Series Programming Manual

Motion controller
Hide thumbs Also See for MELSEC Q Series:
Table of Contents

Advertisement

5 SEQUENCE INSTRUCTIONS FOR MOTION CPU

5.4.10 Conversion from BCD to BIN (16 bits, 32bits): BIN, DBIN

Setting
data
X
Y
M
(S)
(D)
[Setting data]
[Function]
Bit device
SM
F
T
C
D
[Instruction]
Command
BIN
Command
DBIN
Setting data
(S)
(D)
(1) Conversion from BCD to BIN (16 bits) (BIN)
• Converts BCD data (0 to 9999) at device designated by (S) to BIN data, and
stores at the device designated by (D).
8000
(S) BCD 9999
32768
(D) BIN 9999
Usable device
Word device
W
T
C
SD
Z
BIN
DBIN
Head number of the devices where the BCD data is stored
Head number of the devices where BIN data will be stored
4000 2000 1000 800 400 200 100 80
1
0
0
1
1
0
Thousands digits Hundreds digits
163848192 4096 2048 1024 512 256 128 64
0
0
1
0
0
1
Always filled with 0s
5 - 42
Constant Pointer
Level
K
H
P
N
: Usable
: Only BIN instruction (16 bits)
(S)
(D)
(S)
(D)
Description
(BCD 4/8 digits)
(BIN 16/32 bits)
40
20
10
0
1
1
0
0
1
Tens digits
BIN conversion
32
16
1
1
0
0
0
0
Digit
desig-
Index
nation
8
4
2
1
1
0
0
1
Ones digits
8
4
2
1
1
1
1
1

Advertisement

Table of Contents
loading

Table of Contents