Download Print this page

Mitsubishi Electric MELSEC iQ-F FX5 Programming Manual page 403

Instructions, standard functions/function blocks
Hide thumbs Also See for MELSEC iQ-F FX5:

Advertisement

Example in which outputs are latched
In the following program example, the counter C0 is provided to count X1. When X0 is input, the subroutine P0 is executed only in one scan, and then the
counter is reset and Y7 is output.
[Program example]
X0
CALLP
X1
X0
P0
RST
[Timing chart]
A
X1
3
2
Current
value of
1
C0
RST
Remains reset
C0
Y7
Y7 being output
Example in which latched outputs are reset (countermeasures)
[Program example]
X0
CALLP
X1
X2
RST
X0
P0
RST
SM401
RST
RUN Monitor
(normally OFF)
P0
K10
C0
FEND
C0
Y7
RET
Subroutine is executed.
(1)
Counter
reset
(2)
P0
K10
C0
(1)
Y7
FEND
C0
A
C0
B
(2)
Y7
RET
A: Execution of subroutine P0 triggered by X0
(1): Because the C0 reset instruction is valid, the
current value of C0 remains unchanged even if a
pulses are input.
(2): Outputs are latched.
(1): Program to reset Y7 at an arbitrary timing
(2): Program to reset the preceding C0 reset
instruction inside the subroutine
8 APPLICATION INSTRUCTION
8.4 Structuring Instruction
8
401

Hide quick links:

Advertisement

loading