User`s manual
CHAPTER 5
ADVANCED PROGRAMM1N TECBNIQUES
55
5.3. Interrupt
The interface has the capability to interrupt the PC’s processor when certain event
happen. Dowever, most of the version of BASIC language in MS-DOS operating
system only handles the interrupts from keyboard, light pen, communication port,
game port and BASIC error. To use interrupt capability in BASIC, the software can
replace Function Key 19 and 20 interrupts and can add some ERROR’s to inform
BASIC that there is an interrupt from the IEEE488 interface. When these interrupts
are enabled, Function Keys 19 and 20 cannot be used in their normal mode or the
program will 34 be confused.
EVENTS INTERRUPT
ERROR Error. This interface detects an error. The error number is ERR
128. Check 3-3-18 STATUS routine for the error type.
Fl9 Timeout. The IEEE-488 handshake is hung.
F20 SRQ. The IEEE-488 SRQ line is pulled low active by some
device.
The default condition disables all these interrupts. To enable these interrupts, you
must set bits 9,10 and 11 of SETTING’ when calling the INIT routine.
Bit Set O Set 1 IEEE-488 Interrupt Function Key
9 disable enable SRQ F20
10 disable enable Timeout Fl9
11 disable enable Error Error
The BASIC syntax to claim interrupt traps are
ON KEY (20) GOSUB 100 'Handle SRQ
ON KEY (19) GOSUB 200 'Handle Timeout
ON ERROR GOSUB 300 'Handle Error
The interrupt handling of the IEEE-488 interface software is written for IBM
BASICA Version A3.0 & A3.3 only. Since other BASIC versions may have different
traps for the Function Keys and different address of error number, the IEEE-488
interface inter- 44 rupt handling discussed above may not work.