789
FX
3U
/FX
3UC
Series Programmable Controllers
Programming Manual - Basic & Applied Instruction Edition
35 Interrupt Function and Pulse Catch Function
35.3 Input Interrupt (Interrupt Triggered by External Signal) [Without Delay Function]
31
FN
C
275-FN
C
279
Da
ta
Tr
ans
fe
r 3
32
FN
C
280
-F
N
C
28
9
H
igh Speed
Pr
oces
si
ng 2
33
FN
C
290-FN
C
299
Ext
ensi
on Fi
le
R
egi
st
er
34
SF
C
•S
T
L
Pr
o
g
ra
m
m
in
g
35
In
te
rru
p
t
Funct
ion
36
Sp
e
cia
l De
vic
e
37
E
rro
r C
o
d
e
A
V
e
rs
ion U
p
In
fo
rm
a
tio
n
B
Ex
ec
ut
ion Ti
m
e
s
C
Appl
ic
ab
le
In
st
ru
ct
ion Li
st
3) When counting the number of times of input generation (in the same way as 1-phase high speed counter)
In the program example shown below, external inputs are counted.
4) When catching a short pulse
In the program example shown below, the ON status is held for a certain period of time after a short pulse
turns ON.
Step
0
I201
Interrupt
pointer
When the rising edge of X002 is detected
M8000
RUN monitor
FNC 04
EI
END
FNC 06
FEND
D0
FNC 24
INC
FNC 03
IRET
Interrupts are enabled by EI instruction.
The main program is described.
The main program is finished by FEND
instruction.
When X002 turns ON, "1" is added to the value
of D0.
INC instruction executes increment in every
operation cycle, but the interrupt routine is
executed only once by an input signal.
Accordingly, it is not necessary to use INCP
(pulse operation type) instruction.
Pulse input
X003
M0
ON
ON
TO
TO
Step
0
I301
Interrupt
pointer
When the rising edge of X003 is detected
M8000
RUN monitor
M0
M0
T0
K10
FNC 04
EI
T0
FNC 06
FEND
FNC 03
IRET
END
SET
M0
RST
M0
Interrupts are enabled by EI instruction.
The ON/OFF signal in M0 is utilized in this
program.
The period of time to hold M0 is specified.
After the timer time, M0 is reset.
The main program is finished by FEND
instruction.
When X003 turns ON and the interrupt routine is
executed, M0 is set to ON unconditionally.