Chapter 16 PLC Function ApplicationsMH300
GBIN
Convert GRAY code to BIN
GBIN
Continuous
execution type
GBINP
DGBIN
Continuous
execution type
DGBINP
Flag signal: none
*
*
*
*
*
*
*
*
*
*
*
*
*
R
efer to the function specifications table for each device in series
for the scope of device usage.
S: source device storing GRAY code. D: device storing BIN value after conversion.
Converts the GRAY code corresponding to the value of the device designated by
S that is transformed into a BIN value, and stores it in the device designated by D.
This command converts the value of the absolute position encoder connected with
the PLC’s input
(this encoder usually has an output value in the form of GRAY
code) into a BIN value, and stores it in the designated register.
The valid range of S is as shown below; if you exceed this range, it is an error, and
the command does not execute.
16-bit command: 0–32,767
32-bit command: 0–2,147,483,647
When X20=ON, converts the GRAY code of the absolute position encoder
connected with input points X0–X17 to a BIN value and stores it in D10.
0 0 0 1 10 11 10 0 0
b15
b0
H1971=K6513 0 0 0 0 0 0 111111
X17 X0
GRAY CODE 6513
K4X0
0 1 0 1
0 0 1 0