791
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
2. Example of program to measure the short pulse width using a high speed ring counter
Step
0
I001
Interrupt
pointer
X010
I100
Interrupt
pointer
X010
X010
Measurement data
When the rising edge of
X000 is detected
When the falling edge of
X001 is detected
D8099 is set to ON
Measurement
is completed
FNC 04
EI
M8099
FNC 06
FEND
FNC 03
IRET
FNC 12
M0V
FNC 03
IRET
END
RST
D8099
RST
M0
D8099
D0
SET
M0
When X001 turns OFF: The ring counter value
is transferred to D0,
and measurement is
completed.
Interrupts are enabled by EI instruction.
The main program is described.
The ring counter is set to ON.
When X000 turns ON: The ring counter is reset
to OFF, and
measurement is started.
The special data register M8099 up-counts the
0.1 ms clock from the next operation cycle after
being driven.
When the count value exceeds "32767", it is
returned to "0".