Disabling/Enabling Interrupts - Siemens SIMATIC S5-95F Manual

Table of Contents

Advertisement

STEP 5 Operations
8.2.8

Disabling/Enabling Interrupts

The disable/enable interrupt operations affect interrupt-driven and time-controlled program scanning.
They prevent process or time interrupts from interfering with the processing of a sequence of
statements or blocks.
Note that the STATUS function cannot be used on blocks which are invoked between an IA and an
RA operation in the quasi-safety mode.
Safety Note
Note that the interrupt response time may increase by the duration of the interrupt
disable. If possible, never disable interrupts for more than 5 ms. If they are disabled for a
longer period, the S5-95F responds as follows:
After 5 ms, the S5-95F reports error 12, i.e. "Error in user program, interrupts
disabled too long". There is no other response (the system remains at RUN).
After 10 ms, the S5-95F resports error 4, i.e. "Too many interrupts", and goes to
STOP to protect its failsafety.
If your process requires a system reponse after 5 ms, you must program it yourself.
Single out the error with the number 13 by evaluating the system event DB in OB37.
Operation
Operand
IA
RA
Processing
Execution of the disable/enable interrupt operations does not depend on the RLO. These operations
do not affect the RLO or the condition codes. After the "IA" statement is processed, no more
interrupts are executed. The "RA" statement cancels the effect of "IA".
Example
Disable interrupt processing in a
specific program section and then
enable it again.
8-52
Table 8.18 Disable/Enable Interrupt Operations
Disable interrupt
Enable interrupt
=
IA
A
JU
RA
Meaning
STL
.
.
Q
1.0
Disable interrupt.
I
0.0
.
.
.
If an interrupt occurs, the program
FB
3
section between the "IA" and
.
"RA" is scanned without
.
interruption.
.
Enable interrupt.
Interrupts that occurred in the
.
meantime are processed after the
.
"RA" operation.
.
S5-95F
Explanation
EWA 4NEB 812 6210-02

Advertisement

Table of Contents
loading

Table of Contents