393
Conversion Instructions Section 3-11
Description BCD(024) converts the binary data in S to BCD data and writes the result to
R.
Flags
Precautions The content of S must not exceed 270F (9999 decimal).
Example The following diagram shows an example BCD-to-binary conversion.
3-11-4 DOUBLE BINARY-TO-DOUBLE BCD: BCDL(059)
Purpose Converts 8-digit hexadecimal (32-bit binary) data to 8-digit BCD data.
Ladder Symbol
Variations
Timer Area T0000 to T4095
Counter Area C0000 to C4095
DM Area D0 to D32767
Indirect DM addresses
in binary
@ D0 to @ D32767
Indirect DM addresses
in BCD
*D0 to *D32767
Constants ---
Data Registers DR0 to DR15
Index Registers ---
Indirect addressing
using Index Registers
,IR0 to ,IR15
–2048 to +2047 ,IR0 to –2048 to +2047 ,IR15
DR0 to DR15, IR0 to IR15
,IR0+(++) to ,IR15+(++)
,–(– –)IR0 to, –(– –)IR15
Area S R
(BCD)(BIN)
R
Name Label Operation
Error Flag ER ON if the content of S exceeds 270F (9999 decimal).
OFF in all other cases.
Equals Flag = ON if the result is 0000.
OFF in all other cases.
R
×16
3
×16
2
×16
1
×16
0
×10
3
×10
2
×10
1
×10
0
BCDL(059)
S
R
S: First source word
R: First result word
Variations Executed Each Cycle for ON Condition BCDL(059)
Executed Once for Upward Differentiation @BCDL(059)
Executed Once for Downward Differentiation Not supported
Immediate Refreshing Specification Not supported