Fnc 18 - Bcd / Conversion To Binary Coded Decimal - Mitsubishi Electric FX3G SERIES Programming Manual

Programmable controllers
Hide thumbs Also See for FX3G SERIES:
Table of Contents

Advertisement

FX
/FX
/FX
Series Programmable Controllers
3G
3U
3UC
Programming Manual - Basic & Applied Instruction Edition
9.9
FNC 18 – BCD / Conversion to Binary Coded Decimal
Outline
This instruction converts binary (BIN) data into binary-coded decimal (BCD) data.
Binary data is used in operations in PLCs. Use this instruction to display numeric values on the seven-segment
display unit equipped with BCD decoder.
1. Instruction format
FNC 18
D
P
BCD
2. Set data
Operand Type
S
D
3. Applicable devices
Bit Devices
Oper-
and
System User
Type
X Y M T C S D .b KnX KnY KnM KnS T C D R U \G
S
D
: This function is supported only in FX
Explanation of function and operation
1. 16-bit operation (BCD and BCDP)
This instruction converts the binary (BIN) data of
converted BCD data to
• The data of
S
• The table below shows digit specification for
Command
input
FNC 18
BCD
D
K1Y000
K2Y000
K3Y000
K4Y000
Mnemonic
16-bit Instruction
BCD
5 steps
BCDP
Word device number storing the conversion source (binary) data
Word device number of the conversion destination (binary-coded decimal) data
Digit Specification
/FX
3U
3UC
.
D
can be converted if it is ranging from K0 to K9999 (BCD).
S
D
When "K4Y000" is specified
Number of digits
1
2
3
4
9 Move and Compare – FNC 10 to FNC 19
9.9 FNC 18 – BCD / Conversion to Binary Coded Decimal
Operation Condition
32-bit Instruction
Continuous
9 steps
Operation
Pulse (Single)
Operation
Description
Word Devices
Special
System User
Index
Unit
V
Z Modify K H
PLCs.
S
into binary-coded decimal (BCD) data, and transfers the
S
and
D
.
PLC
BCD (FNC 18)
...
...
...
Y014
Y010 Y004 Y000
...
...
...
Y017
Y013 Y007 Y003
Data range
0 to 9
00 to 99
000 to 999
0000 to 9999
Mnemonic
Operation Condition
DBCD
Continuous
Operation
DBCDP
Pulse (Single)
Operation
Data Type
16- or 32-bit binary
16- or 32-bit binary
Others
Con-
Real
Charac-
stant
Number
ter String
E
" "
BIN
...
...
BCD
1
2
3
4
5
Pointer
P
6
7
8
9
10
263

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fx3u seriesFx3uc series

Table of Contents