Flags function, Hint, 2 instructions – Omron SYSMAC CP CP1E-N@@D@-@ User Manual
Page 337: Operand specifications
2-301
2 Instructions
CP1E CPU Unit Instructions Reference Manual(W483)
I
n
terru
pt C
ont
ro
l I
n
stru
ctio
ns
2
MSKS
Operand Specifications
Flags
Function
When the program execution starts, the interrupt inputs that generate I/O interrupt tasks are masked
(disabled), and the internal timers creating the timer interrupts that generate scheduled interrupt tasks
are stopped.
Use MSKS(690) to enable the I/O interrupts and timer interrupts, so that the corresponding interrupt
tasks can be executed.
The value of N specifies the interrupt task and the kind of processing that will be performed.
(1) N = 102 to 107: Enabling/Disabling the Interrupt Inputs of I/O Interrupt Tasks
• Enables or disables the interrupt inputs specified by N, based on the status of the bits in C. With
this function, MSKS(690) can control whether or not each task is executed.
• When an interrupt input is enabled, any interrupts detected up to that point will be cleared.
(2) N = 112 to 117: Specifying the Differentiation of Interrupt Inputs
• Specifies whether the interrupt inputs specified by N are up-differentiated or down-differentiated,
based on the status of the bits in C.
• Use the differentiation specification together with the enabling/disabling function. If MSKS(690) is
not executed to specify up or down differentiation, the interrupt inputs are up-differentiated (the
default setting).
• When MSKS(690) is executed to specify an interrupt input’s up or down differentiation, any inter-
rupts detected up to that point will be cleared.
(3) N = 4 or 14: Resetting and Restarting Scheduled Interrupt Tasks
• Sets the time interval (specified by C) for the specified scheduled interrupt task (specified by N),
resets the internal timer’s PV, and starts the internal timer. Since the internal timer’s PV is reset,
this function maintains the proper interval from the execution of MSKS(690) until the start of the
first interrupt .
Hint
The longest interrupt task processing time is stored in A440 (Maximum Interrupt Task Processing
Time). At the same time, the task number of the interrupt task with the longest interrupt task processing
time is stored in A441 (Interrupt Task with Maximum Processing Time).
Area
Word addresses
Indirect DM addresses
Constants
CF
Pulse bits
TR bits
CIO
WR
HR
AR
T
C
DM
@DM
*DM
N
---
---
---
---
---
---
---
---
---
OK
---
---
---
C
OK
OK
OK
OK
OK
OK
OK
OK
OK
Name
Label
Operation
Error Flag
P_ER
ON if N is not within the specified range.
Errors when specifying I/O Interrupts:
• The Error Flag will go ON if C is not within the specified range.
Errors when specifying Scheduled Interrupts:
• The Error Flag will go ON if C is not between 10 and 9,999 decimal (000A to 270F hex).
OFF in all other cases.