Interrupt Handling; Figure 13: Conflict Avoidance When Using Interrupt-Driven Blocks - GE PACSystems RX7i Cpu Programmer's Reference Manual

Hide thumbs Also See for PACSystems RX7i:
Table of Contents

Advertisement

Chapter 2. Program Organization
2.3.1

Interrupt Handling

An I/O, Module, or Timed interrupt can be associated with any block except _MAIN, as long as the
block has no parameters other than an OK output. After an interrupt has been associated with a
block, that block executes each time the interrupt trigger occurs. A given block can have multiple
timed, I/O, and module interrupt triggers associated with it. It is executed each time any one of its
associated interrupts triggers. For details on how interrupt blocks are prioritized, refer to Interrupt
Block Scheduling.
If a parameterized block or external block is triggered by an interrupt, it inherits %P data as its %L
local data. For example, a %L00005 reference in the parameterized block or C block actually
references %P00005.
Note: Timer function blocks do not accumulate time if used in a block that is executed as a result of
an interrupt.
Blocks that are triggered by interrupts can make calls to other blocks. The application stack used
during interrupt-driven execution is different from the stack used during normal block-structured
program execution. In particular, the nested call limit is different from the limit described for calls
from the _MAIN block. If a call results in insufficient stack space to complete the call, the CPU logs an
Application Stack Overflow fault.
Note: We strongly recommend that interrupt-driven blocks not be called from the _MAIN block or
other non-interrupt driven blocks because the interrupt and non-interrupt driven blocks
could be reading and writing the same global memories at indeterminate times relative to
each other. In the following example (Figure 13) INT1, INT2, BLOCK5, and PB1 should not be
called from _MAIN, BLOCK2, BLOCK3, or BLOCK4.
_MAIN
Block

Figure 13: Conflict Avoidance when using Interrupt-Driven Blocks

26
PACSystems* RX7i, RX3i and RSTi-EP CPU Programmer's Reference Manual
INT Block 1
INT Block 2
Block
2
Block
3
Block
4
Block
5
PB
1
GFK-2950C

Advertisement

Table of Contents
loading

This manual is also suitable for:

Pacsystems rx3iPacsystems rsti-ep

Table of Contents