332
6 BASIC INSTRUCTIONS
6.7 I/O Refresh Instructions
6.7 I/O Refresh Instructions
I/O refresh
RFS(P)
• Refreshes only the device being scanned during a scan, and functions to fetch input from external sources or to output data
to an output module.
• Fetching of input from or sending output to an external source is conducted in batch only after the execution of the END
instruction, so it is not possible to output a pulse signal to an outside source during the execution of a scan. When the I/O
refresh instruction is executed, the inputs (X) or outputs (Y) of the corresponding device numbers are refreshed forcibly
midway through program execution. Therefore, a pulse signal can be output to an external source during a scan.
• Use direct access inputs (DX) or direct access outputs (DY) to refresh inputs (X) or outputs (Y) in 1-point units.
• In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into SD0.
(S): Head number of the devices to be refreshed (bits)
n: Number of refreshes (BIN 16 bits)
Setting
data
Internal device R, ZR J\ U\G Zn Constant
K, H
Others
Bit Word Bit Word
(S) (Only X, Y)
n
Error
code
Error details Q00J/
Q00/
Q01
QnH QnPH QnPRH QnU LCPU
4101 The points specified in n exceed those of the proximate I/O.
Basic
Process
High
performance
Redundant
Universal
LCPU
Command
Command
RFSP
RFS
n
n
S
SRFSP
RFS
Command
K1
X0
Command
Y20
X0
RFS
K1
Y20
RFS
Direct access input
DY20
DX0
Direct access output
Refreshes X0
Refreshes Y20
[Program based on the RFS instruction]
[Program based on direct access input and direct access output]