Dgrd (Digital Read) - IDEC FC4A-C10R2 User Manual

Fc4a series microsmart micro programmable logic controller
Table of Contents

Advertisement

DGRD (Digital Read)

DGRD
BCD4
*****
Quantity of digits:
1 to 5 (decimal)
1 to 4 (hex)
Conversion:
BCD or BIN
Applicable CPU Modules
FC4A-C10R2/C
FC4A-C16R2/C
Note: The DGRD instruction requires transistor output terminals. When using all-in-one 24-I/O type CPU module FC4A-C24R2
or FC4A-C24R2C, connect a transistor output module.
Valid Operands
Operand
I
Q
D1 (Destination 1)
For the valid operand number range, see pages 6-1 and 6-2.
The DGRD instruction can read 65535 (5 digits) at the maximum. When the read value exceeds 65535 with the quantity of
digits set to 5, a user program execution error will result, turning on special internal relay M8004 and the ERR LED.
Note: The DGRD instruction can be used up to 16 times in a user program. When transferring a user program containing
more than 16 DGRD instructions to the CPU, a user program syntax error occurs, turning on the ERR LED. The user program
cannot be executed.
Conversion
BCD:
To connect BCD (decimal) digital switches
BIN:
To connect BIN (hexadecimal) digital switches
Input Points
Inputs are used to read the data from digital switches. The quantity of required input points is always 4. Four input points
must be reserved starting with the input number designated by operand I. For example, when input I0 is designated as
operand I, inputs I0 through I3 are used.
Output Points
Outputs are used to select the digits to read. The quantity of required output points is equal to the quantity of digits to read.
When connecting the maximum of 5 digital switches, 5 output points must be reserved starting with the output number
designated by operand Q. For example, when output Q0 is designated as operand Q to read 3 digits, outputs Q0 through
Q2 are used.
Digital Switch Data Reading Time
Reading digital switch data requires the following time after the input to the DGRD instruction is turned on. Keep the
input to the DGRD instruction for the period of time shown below to read the digital switch data. For example, when read-
ing data from 5 digital switches to the destination operand, 14 scans are required
Digital Switch Data Reading Time
2 scan times × (Quantity of digits + 2)
I
Q
D1
*****
*****
First output number
First input number
FC4A-C24R2/C
X
Function
First input number to read
First output number for digit selection
Destination to store results
« FC4A M
When input is on, data designated by operands I and Q is set
to a data register designated by destination operand D1.
This instruction can be used to change preset values for timer
and counter instructions using digital switches. The data that
can be read using this instruction is 0 through 65535 (5 dig-
its), or FFFFh.
FC4A-D20K3/S3
X
I
Q
X
— — — — — —
X
— — — — — —
S
U
'
M
ICRO
MART
SER
S
ANUAL
16: I
NTERFACE
FC4A-D20RK1/RS1 & FC4A-D40K3/S3
X
M
R
T
C
D
Constant
— — — — —
X
»
I
NSTRUCTIONS
Repeat
16-3

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents