Specifications

Timed Interrupt Program Example
The following program selects Mode 40, then selects the timed interrupt option, with an
interrupt period of 100 ms.
Inputs X0, X1, and X2, are configured as filtered inputs with a 10 ms time constant. Note
that X0 uses the time constant from X1. The program is otherwise generic, and may be
adapted to your application.
DL05 Micro PLC User Manual, 6th Edition, Rev. C
E–48
Appendix E: High-speed Input and Pulse Output Features
1
2
3
D
E
6
7
8
9
10
11
1
1
14
A
B
C
D
T
ime
Timed
I
nterrupt
1
00 ms
SP0
LD
K40
Load constant K40 into the accumulator. This
selects Mode 40 as the HSIO mode.
OUT
V7633
Output this constant to V7633, the location of the
HSIO Mode select register.
DirectSOFT
Mode 40
LD
K1006
Load the constant K1006 which is required to select
filtered inputs with a 10 ms filter time constant.
OUT
V7635
Output this constant to V7635, configuring X1 and X0.
Filtered Inputs
OUT
V7636
Output this constant to V7636, configuring X2.
LD
K1004
Load the constant K1004 which is required to select
the timed interrrupt option, with a period of 100 ms.
OUT
V7634
Output this constant to V7634, configuring the timed
interrupt for 100 ms period.
Timed Interrupt
INT Enable
ENI
Enable Interrupts at the beginning of the program.
END
END coil marks the end of the main program.
INT O0
IRT
Return to the main ladder program.
The INT label marks the beginning of the interrupt
service routine program.
Main Program
Insert Main Program rungs here for your application.
Interrupt Routine
Insert interrupt service routine rungs here for your
application.
SP1
LD
K1
Load constant K1 into the accumulator.
ADD
V2000
OUT
V2000
Add the value in the accumulator with the value in
memory location V2000.
Output the result into memory location V2000.