Fnc171 - Gbin / Gray Code To Decimal Conversion - 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
22.2
FNC171 – GBIN / Gray Code to Decimal Conversion
Outline
This instruction converts a gray code into a binary value, and transfers it.
1. Instruction format
FNC 171
D
GBIN
P
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
S
D
: This function is supported only in FX
Explanation of function and operation
1. 16-bit operation (GBIN and GBINP)
Command
input
FNC171
GBIN
When
S
is K3X000 and
GRY 1234
D10
BIN 1234
- This instruction can be used for detecting an absolute position by a gray code type encoder.
-
S
can store a value from 0 to 32,767.
2. 32-bit operation (DGBIN and DGBINP)
- A gray code can be converted into a binary value of up to 32 bits.
-
can store a value from 0 to 2,147,483,647.
S
Caution
When an input relay (X) is specified as
The input filter value in X000 to X017
adjustment) so that the delay caused by the filter constant is eliminated.
*1.
X000 to X007 in FX
Mnemonic
16-bit Instruction
GBIN
5 steps
GBINP
Conversion source data or word device storing conversion source data
Word device storing data after conversion
Digit Specification
/FX
3U
3UC
This instruction converts and transfers data from
S
D
the source (gray code) to the destination (binary).
D
is D10
X13
X10 X7
0
1
1
0
1
0
b15
0
0
0
0
0
1
0
0
1
1
S
, the response relay will be "Scan time of PLC + Input filter constant".
*1
can be converted using the REFF (FNC51) instruction or D8020 (filter
PLCs
3G
22 External Device – FNC170 to FNC179
22.2 FNC171 – GBIN / Gray Code to Decimal Conversion
Operation Condition
32-bit Instruction
Continuous
9 steps
Operation
Pulse (Single)
Operation
Description
Word Devices
Special
System User
Index
Unit
T
C D R U \G
V
Z Modify K
PLCs.
X0
1
1
1
0
1
1
b0
0
1
0
0
1
0
Mnemonic
Operation Condition
DGBIN
Continuous
Operation
DGBINP
Pulse (Single)
Operation
Data Type
16- or 32-bit binary
16- or 32-bit binary
Others
Con-
Real
Charac-
Pointer
stant
Number
ter String
H
E
" "
P
583
21
22
23
24
25
26
27
28
29
30

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fx3u seriesFx3uc series

Table of Contents