Mitsubishi Electric MELSEC-Q/L Programming Manual page 99

Hide thumbs Also See for MELSEC-Q/L:
Table of Contents

Advertisement

• BCD_TO_DINT, BCD_TO_DINT_E
Converts BCD type data input to (s) into double word (signed) type data, and outputs the operation result from (d).
• When word (unsigned)/16-bit string is specified for (s)
s
9999
H
Word (unsigned)/16-bit string type
9999
H
9999
0
0
0
0
0
1
0
1
1
1
Always filled with 0s.
• When double word (unsigned)/32-bit string is specified for (s)
s
99999999
Double word (unsigned)/32-bit string type
×
×
99999999
1
0
0
1
1
0
0
1
H
Ten
Millions
millions
place
place
99999999
0
0
0
0
0
1
0
1
Always filled with 0s.
The value to be input to (s) is word (unsigned)/16-bit string type data within the range from 0H to 9999H (0 to 9 for each digit),
double word (unsigned)/32-bit string type data within the range from 0H to 99999999H (0 to 9 for each digit).
Word (unsigned)/16-bit string, double word (unsigned)/32-bit string type can be specified for (d). Bit type cannot be specified.
■Operation result
• Function without EN/ENO
An operation is executed and the operation value is output from (d).
• Function with EN/ENO
The following table shows the executing conditions and operation results.
EN
TRUE (Operation execution)
FALSE (Operation stop)
*1 When FALSE is output from ENO, the data output from (d) is undefined. In this case, create a program so that the data output from (d) is
not used.
Double word (signed) type
×
×
1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1
Thousands
Hundreds
place
place
1
1
0
1
0
1
1
1 1 0 0 0 0 0 1 1 1 1 1 1 1 1
H
Double word (signed) type
×
×
×
×
1
0
0
1
1
0
0
1
1
0 0 1 1 0 0 1 1 0 0 1 1 0 0 1
Hundred
Ten
Thousands
Hundreds
thousands
thousands
place
place
place
place
DINT conversion
1
1
1
1
0
1
0
1
1
1 1 0 0 0 0 0 1 1 1 1 1 1 1 1
ENO
TRUE
*1
FALSE
d
9999
×
×
Tens
Units
place
place
DINT conversion
d
99999999
×
×
Tens
Units
place
place
(d)
Operation output value
Undefined value
5 APPLICATION FUNCTIONS
5.1 Type Conversion Functions
5
97

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents