
<
2
.75
7UGT U/CPWCN
=L/2*
+PVGTTWRVU
7/<:
POLLED PROCESSING
Polled interrupt processing is supported by masking off the
IREQ
to be polled. This process is accomplished
by setting the corresponding bits in the
IMASK
to 0.
To initiate polled processing, check the appropriate bits in the
IREQ
using the Test Under Mask (
TM
) instruc-
tion. If the bit is set to 1, call or branch to the service routine. The service routine services the request, resets
its Request Bit in the
IREQ
, and branches or returns back to the main program. An example of a polling
routine is as follows:
TM IREQ,#MASKA;Test for request
JR Z, NEXT;If no request go to NEXT
CALL SERVICE;If request is there,then
;service it
NEXT:
.
.
.
SERVICE:;Process Request
.
.
.
AND IREQ, #MASKB ;Clear Request Bit
RET;Return to next
In this example, if
IREQ2
is being polled,
MASKA
is
00000100B
and
MASKB
is
11111011B
.
RESET CONDITIONS
The
IMASK
and
IREQ
registers initialize to
00H
on
RESET
.