Outputs Generating Interrupts - Omron CJ1W-CT021 Operation Manual

High-speed counter units
Hide thumbs Also See for CJ1W-CT021:
Table of Contents

Advertisement

Interrupts
4-6-1

Outputs Generating Interrupts

Enabling / Disabling
Interrupts
General Setting:
External Interrupt Task
Offset
The 32 Outputs, divided in 2 Digital Outputs and 30 Soft Outputs, can all be con-
figured to generate interrupts to the CJ-series CPU Unit. If an Output is configured
to generate interrupts, an interrupt is issued to the CJ-series CPU Unit at a rising
and at a falling edge of the corresponding bit in the Unit Output Pattern. For this
purpose two external interrupt tasks in the CJ-series CPU Unit are assigned to
every Output. In the external interrupt task you should write an appropriate (lad-
der) program that takes the required action on the occurrence of an interrupt.
You can configure an Output to generate interrupts by setting the corresponding
bit in the Interrupt Enable Data of the Outputs. The Interrupt Enable Data of the
Outputs consists of 32 bits representing the 32 Outputs. By default Outputs are
disabled to generate interrupts.
15 14 13 12 11 10 9
m+2
15 14 13 12 11 10 9
m+3
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
= Digital Outputs 0-1
(corresponding to Physical Digital Outputs O0 and O1)
= Soft Outputs 2-31
0 = Interrupts Disabled
1 = Interrupts Enabled
Every Output that is enabled to generate interrupts is assigned two External Inter-
rupt Tasks in the CJ-series CPU Unit. For this purpose all 32 Outputs are assigned
in sequential order to consecutive External Interrupt Tasks starting from Output 0.
By defining an Offset you determine the External Interrupt Task numbers of the
(first two) External Interrupt Tasks that are assigned to Output 0. The remaining 31
Outputs are assigned to the respective External Interrupt Task numbers in
increasing order starting from "Offset + 2".
Output
0 (=O0)
1 (=O1)
2
3
4
~
8
7
6
5
4
3
2
1
8
7
6
5
4
3
2 O1 O0
Assigned External
Interrupt Task Number
Offset
Offset + 1
Offset + 2
Offset + 3
Offset + 4
Offset + 5
Offset + 6
Offset + 7
Offset + 8
Offset + 9
~
0
Interrupt Enable Data
Outputs
Interrupt executed at
rising/falling edge*
Rising
Falling
Rising
Falling
Rising
Falling
Rising
Falling
Rising
Falling
~
Section 4-6
129

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents