Omron CP1H CPU Operation Manual page 229

Cp1h cpu unit
Hide thumbs Also See for CP1H CPU:
Table of Contents

Advertisement

Interrupt Functions
Note
Writing the Interrupt
Task's Program
Input Interrupt
Settings and
Operation
Settings
1,2,3...
Operation
MSKS(690) Operands
Input interrupt
Interrupt
number
task
number
Input interrupt 0
140
Input interrupt 1
141
Input interrupt 2
142
Input interrupt 3
143
Input interrupt 4
144
Input interrupt 5
145
Input interrupt 6* 146*
Input interrupt 7* 147*
*Input interrupts 2 and 3 are not supported by the Y CPU Units.
Create programs for interrupt tasks 140 to 147, which are executed by the cor-
responding input interrupt. Always put an END(001) instruction at the last
address of the program.
This example shows how to execute interrupt task 141 when 200 up-differenti-
ated pulses have been counted at input CIO 0.01. (The counter is an incre-
menting counter.)
1. Connect an input device to input 0.00.
2. Use the CX-Programmer to set input 0.01 as an input interrupt in the PLC
Setup.
3. Use the CX-Programmer to create the program to use for interrupt pro-
cessing and allocate the program to interrupt task 141.
4. Use the CX-Programmer to set a high-speed counter SV of 00C8 hex (200
decimal) in A533.
5. Use the CX-Programmer to write MSKS(690) in the program.
W0.00
(Execution condition)
@ MSKS(690)
111
#0000
@MSKS(690)
111
#0003
When execution condition W0.00 goes ON, MSKS(690) is executed to enable
operation of the input interrupt in counter mode.
1. Up-differentiation or
Down-differentiation
N
S
Input
Count
interrupt
trigger
number
110 (or 10) #0000: Up-
differenti-
111 (or 11)
ated pulses
112 (or 12)
#0001:
113 (or 13)
Down-dif-
ferentiated
114
pulses
115
116
117
Specifies input interrupt 1.
Specifies up-differentiated pulses.
Specifies input interrupt 1.
Specifies an incrementing counter,
starts counting, and enables the input
interrupt.
Section 5-1
2. Enabling/Disabling the
input interrupt
N
S
Input
Enable/
interrupt
Disable
number
100 (or 6)
#0002: Start
counting down
101 (or 7)
(decrement-
102 (or 8)
ing) and enable
103 (or 9)
interrupts
#0003: Start
104
counting up
105
(incrementing)
106
and enable
interrupts
107
195

Advertisement

Table of Contents
loading

Table of Contents