< Previous  |  Contents  |  Next >

A: Interrupt Summaries    
   

The Interrupt Vectors

It should be noted that these vectors are as set in an unexpanded 512 running an unmodified DOS Plus 2.1 with no software loaded except COMMAND.COM. Users are warned that loading almost any application program may damage some of the vectors. These vector contents should never be accessed directly.

Access should be either by an implicit program jump as a result of a call to the appropriate interrupt or, when intercepting vectors, by the legal means of INT 21h function 25h or 35h.

In the table below the interrupts are grouped. In all cases the table shows the hex and decimal interrupt number, the offset of the vector in segment zero, the segment and offset of the vector contents and the function.

Internal Hardware Interrupts

Interrupt       Seg0:   Vectored to
Hex     Dec     Offs    Seg:Offset     
Function

00       0      0000    06BB:47B5       Divide by zero overflow
0l       1      0004    06BB:47CC       Single step error
02       2      0008    06BB:119F       Non Maskable Interrupt
03       3      000C    06BB:47D6       Breakpoint
04       4      0010    06BB:47DB       Overflow error
05       5      0014    06BB:47E0       Bounds (range) error
06       6      0018    06BB:47E5       Invalid Opcode
07       7      001C    06BB:47EA       'ESC' opcode exception
08       8      0020    06BB:1658       Hardware timer tick
09       9      0024    0000:0000            Not supported
0A      10      0028    0000:0000            Not supported
0B      11      002C    0000:0000            Not supported
0C      12      0030    06BB:0713       Tube register 1 or 4 interrupt
0D      13      0034    0000:0000            Not supported

External Hardware Interrupts (IBM ROS Emulation)

0E      14      0038    0000:0000       Not supported (PC FDC)
0F      15      003C    0000:0000       Not supported (PC FDC)
10      16      0040    06BB:21F1       Display services for PC monitors
11      17      0044    06BB:2729       Return equipment flags for PC
12      18      0048    06B3:2734       Return memory size for PC
13      19      004C    0B4E:06EE       if AH = 8 Return number of floppy drives
                                        else
                                        error = 'Unsupported IBM XT ROS call'
14      20      0050    06BB:2740       Async services int for PC Comm ports
15      21      0054    068B:2801       Cassette services interrupt – Not supported
16      22      0058    06BB:2802       Keyboard Driver (Dummy-returns)
17      23      005C    06BB.287A       Printer driver
18      24      0060    063B:2935       (ROM BASIC)
19      25      0064    06BB:28EA       (Bootstrap loader)
1A      26      0068    06BB:1661       IBM time of day
1B      27      006C    0B4E:10DC       IBM ROS kbd. break (Dummy-returns) §
1C      28      0070    06BB:4794       IBM ROS tick (Dummy-returns)
1D      29      0074    068B:2199       Video parameter address pointer §
1E      30      0078    06BB:218E       Disc parameter table pointer §
1F      31      007C    0000:0000       Not supported (Graphics char table in PC)

MS-DOS Interrupts

20      32      0080    0B4E:0756       Terminate process (obsolete)
21      33      0084    0B4E:07B1       General function despatcher
22      34      0088    0B4E:069F       Terminate handler address §
23      35      008C    0B4E:08E1       CTRL-C handler address §
24      36      0090    0B4E:0A84       Critical error handler address §
25      37      0094    0B4E:0B43       Absolute disc read
26      38      0098    0B4E:0B99       Absolute disc write
27      39      009C    0B4E:0BBD       Terminate and stay resident (obsolete)

MS-DOS Interrupts - Reserved for Future Use

28      40      00A0    06BB:4794       Wait for keyboard input (Dummy-returns)
29      41      00A4    0000:0000            INT 29h through to 2Eh are
2E      46      00B8    O000:0000            not supported – vectors zero
2F      47      00BC    06BB:4794       MS-DOS print spooler (Dummy-returns)
30      48      00C0    0000:0000            INT 48h-63h are
3F      63      00FC    0000:0000            not supported – vectors zero
40      64      0100    F000:lDAC       Host OSFIND (f/disc driver on PC/XT)
41      65      0104    F000:1DCF       Host OSGBPB (h/disc param. table PC/XT)
42      66      0108    F00D:1F1F       Host OSBPUT
43      67      Ol0C    F000:1F3B       Host OSBGET
44      68      0110    F000:1F4F       Host OSARGS (Graphics chr. table PC Jnr)
45      69      0114    F000:1F93       Host OSFILE
46      70      0118    F000:19B0       Host OSRDCH
47      71      011C    F000:19D8       Host OSASCI
48      72      0120    F000:19DD       Host OSNEWL
49      73      0124    F0D0:19E5       Host OSWRCH
4A      74      0128    F000:1E6D       Host OSWORD
4B      75      012E    F000:1E10       Host OSBYW
4C      76      0130    F000:lA11       Host OSCLI
4D      77      0134    0000:0000            Not supported
4E      78      0138    0000:0000            Not supported
4F      79      013C    F000:2048       80186 error handler
50      80      0140    0000:0000            INTs 50h to DFh are
DF     223      037C    0000:0000            not supported – vectors zero

In the above range 60h to 67h are the user vectors, while 67h is used for EMS in later PCs.

CP/M (86)/BDOS calls (Available to DOS Plus)

E0     224      0380    0060:0144       Direct call to BDOS (See below)

Unused – Reserved for Future MS/PC-DOS Expansion

El     225      0384    0000:0000            INTs Elh to FDh are
F0     253      03F4    0000:0000            not supported – vectors zero

Acorn 512 'Specials'

FE     254     03F8    06BB:4795       SYSDAT vector for GEM (Kills INT 224)
FF     255      03FC    06BB:47F4       80186 register dump on critical error

§ These are pointers to code or data tables and must not be called directly.

‡ These are incomplete implementations or supply suitable simulated return information.

INT 21h Summary by Function Number

In the following list all interrupt functions are shown for completeness. The function number is always in register AH.

A '§' indicates that the function is available in MS-DOS v2.0 onwards, but is not officially recognised or supported by the Microsoft Corporation.

A '‡' against the function indicates that the call is incompatible with DOS Plus 2.1 for the reason shown.

Hex      Dec    Function type

00       00     Terminate process
01       01     Character input with echo
02       02     Character output
03       03     Auxiliary input
04       04     Auxiliary output
05       05     Printer output
06       06     Direct console input/output
07       07     Unaltered character input no echo
08       08     Character input without echo
09       09     Display string
0A       10     Buffered keyboard input
0B       11     Check input status
0C       12     Flush input buffer then input
0D       13     Drive reset
0E       14     Select drive
0F       15     Open file
10       16     Close file
11       17     Find first file
12       18     Find next file
13       19     Delete file
14       20     Sequential read
15       21     Sequential write
16       22     Create file
17       23     Rename file
18       24     MS-DOS Reserved function ‡
19       25     Get current drive
1A       26     Set disc transfer area (DTA) address
1B       27     Get default drive data
1C       28     Get drive data
1D       29     MS-DOS Reserved function ‡
1E       30     MS-DOS Reserved function ‡
1F       31     MS-DOS Reserved function ‡
20       32     MS-DOS Reserved function ‡
21       33     Random read
22       34     Random write
23       35     Get file size
24       36     Set relative record number
25       37     Set interrupt vector
26       38     Create new PSP
27       39     Random block read
28       40     Random block write
29       41     Parse filename
2A       42     Get date
2B       43     Set date
2C       44     Get time
2D       45     Set time
2E       46     Set verify flag (non-functional in DOS Plus)
2F       47     Get DTA address
30       48     Get DOS version number
31       49     Terminate and stay resident
32       50     Get disc information (undocumented call) §‡
33       51     Get or set break flag (non-functional in DOS Plus)
34       52     Find active byte (undocumented call) §‡
35       53     Get interrupt vector
36       54     Get drive allocation data
37       55     Set or get DOS switch character
38       56     Get or set country information
39       57     Create directory
3A       58     Delete directory
3B       59     Set current directory
3C       60     Create file
3D       61     Open file
3E       62     Close file
3F       63     Read file or device
40       64     Write file or device
41       65     Delete file
42       66     Set file pointer
43       67     Get or set file attributes
44       68     I/O control
45       69     Duplicate handle
46       70     Redirect handle
47       71     Get current directory
48       72     Allocate memory block
49       73     Release memory block
4A       74     Resize memory block
4B       75     Execute program
4C       76     Terminate process with return code
4D       77     Get return code
4E       78     Find first file
4F       79     Find next file
50       80     Set address of PSP (undocumented call) §‡
51       81     MS-DOS Reserved function ‡
52       82     MS-DOS Reserved function ‡
53       83     MS-DOS Reserved function ‡
54       84     Get verify flag (non-functional in DOS Plus) ‡
55       85     MS-DOS Reserved function ‡
56       86     Rename file (not implemented) ‡
57       87     Get or set file date and time stamps (not implemented) ‡
58       88     Get or set allocation strategy (DOS Version 3.0+) ‡
59       89     Get extended error information (DOS Version 3.0+) ‡
5A       90     Create temporary file (DOS Version 3.0+) ‡
5B       91     Create new file (DOS Version 3.0+) ‡
5C       92     Lock or unlock file region (DOS Version 3.0+) ‡
5D       93     MS-DOS Reserved function ‡
5E       94     Get machine name/Get or set printer setup (DOS Version 3.1+) ‡
5F       95     Device redirection (DOS Version 3.1+) ‡
60       96     MS-DOS Reserved function ‡
61       97     MS-DOS Reserved function ‡
62       98     Get PSP address (DOS Version 3.0+)‡
63       99     Get lead byte table (DOS Version 2.25 only) ‡
64      100     MS-DOS Reserved function ‡
65      101     Get extended country information (DOS Version 3.3+) ‡
66      102     Get or set code page (DOS Version 3.3+) ‡
67      103     Set handle count (DOS Version 3.3+) ‡
68      104     Commit file (DOS Version 3.3+) ‡
E0      224     Call BDOS (See below)

INT 21h Function Summary by Operation Type

In the following list only interrupts compatible with DOS version 2 and which should be available in DOS Plus 2.1 are shown. Where a function has (V.1) shown, it is the original implementation from DOS version 1 and has been superseded or has improved facilities in the later call referred to, which should generally be used in preference. Calls marked ‡ are not usable in the 512 even though they are DOS 2.1 calls.

Hex      Dec    Function type

Character Input/output

0l        1     Character input with echo
02        2     Character output
03        3     Auxiliary input
04        4     Auxiliary output
05        5     Printer output
06        6     Direct console input/output
07        7     Unfiltered character input without echo
08        8     Character input without echo
09        9     Display string
0A       10     Buffered keyboard input
0B       11     Check input status
0C       12     Flush input buffer then input

Disc Operations

0D       13     Drive reset
0E       14     Select drive
19       25     Get current drive
1B       27     Get default drive data
1C       28     Get drive data
2E       46     Set verify flag
32       50     Get disc information (undocumented call) §
36       54     Get drive allocation data
54       84     Get verify flag

Directory Operations

39       57     Create directory
3A       58     Delete directory
3B       59     Set current directory
47       71     Get current directory

File Operations

0F       15     Open file (V.1 use 3D)
10       16     Close file (V.1 use 3E)
11       17     Find first file (V.1 use 4E)
12       18     Find next file (V.1 use 4F)
13       19     Delete file (V.1 use 41)
16       22     Create file (V.1 use 3C)
17       23     Rename file
23       35     Get file size
29       41     Parse file name
3C       60     Create file
3D       61     Open file
3E       62     Close file
41       65     Delete file
43       67     Get or set file attributes
45       69     Duplicate handle
46       70     Redirect handle
4E       78     Find first file
4F       79     Find next file
56       86     Rename file
57       87     Get or set file date and time

Record Operations

14       20     Sequential read
15       21     Sequential write
lA       26     Set disk transfer area (DTA) address
21       33     Random read (See 27)
22       34     Random write (See 28)
24       36     Set relative record number
27       39     Random block read
28       40     Random block write
2F       47     Get DTA address
3F       63     Read file or device
40       64     Write file or device
42       66     Set file pointer

Process Management

00       00     Terminate process (V.1 use 4C)
26       38     Create new PSP (V.1 use 4B)
31       49     Terminate and stay resident
34       52     Find active byte (undocumented call) §‡
4B       75     Execute program
4C       76     Terminate process with return code
4D       77     Get return code
50       80     Set address of PSP (undocumented call) §‡

Memory Management

48       72     Allocate memory block
49       73     Release memory block
4A       74     Resize memory block

Time/Date Functions

2A       42     Get date
2B       43     Set date
2C       44     Get time
2D       45     Set time

Miscellaneous System Functions

25       37     Set interrupt vector
30       48     Get MS-DOS version number
33       51     Get or set break flag‡ (not implemented) ‡
35       53     Get interrupt vector
37       55     Set or get DOS switch character
38       56     Get or set country information
44       68     I/O control (limited implementation)
E0      224     Call BDOS (see below)

INT E0h (BDOS) Summary by Function Number

In external (ie DOS resident console-connected) programs all functions are initiated by a call to INT 21h with a function code of 0E0h in AH and the BDOS function number in CL. There are gaps in the sequence, either because the call is not implemented up to 2.1, or because it is a pure CP/M function not available in DOS Plus.

Hex      Dec    Function type

00        0     Terminate program (exactly as 8Fh)
01        1     Read a character
02        2     Write a character
03        3     Auxiliary input
04        4     Auxiliary output
05        5     Write a character to the list device
06        6     Direct console I/O
07        7     Auxiliary input status
08        8     Auxiliary output status
09        9     String output
0A       10     Read an edited line
0B       11     Get console status
0C       12     Get BDOS version number
0D       13     Reset all drives
0E       14     Set default drive
0F       15     Open a file for record access
10       16     Close a file
11       17     Search for first matching file
12       18     Search for next matching file
13       19     Delete a file
14       20     Read records sequentially
15       21     Write records sequentially
16       22     Create a file entry
17       23     Rename a file
18       24     Return 'Login Vector' for all logged in drives
19       25     Return the default drive ID
1A       26     Set the DMA buffer offset address
1B       27     Get address of disc allocation vectors
1C       28     Set the default drive to read-only
1D       29     Get read-only drive vectors
lE       30     Set file attributes
1F       31     Get calling process's default disc DPB address
20       32     Get/set current user number
21       33     Read random records
22       34     Write random records
23       35     Return the size of a file
24       36     Set the random record number in the FCB
25       37     Reset the specified drives
26       38             Unallocated
27       39     Free specified drives
28       40     Write random records and zero-fill unallocated blocks
29       41             Unallocated
2A       42             Unallocated
2B       43             Unallocated
2C       44     Set the system multi-sector count
2D       45     Set filing system error mode
2E       46     Return unallocated space on the specified drive
2F       47     Load and execute program specified in DMA buffer
30       48     Write pending internal disc buffers to media
31       49     Get/set system variable
32       50     Call BIOS (XIOS) directly (see below)
33       51     Set the DMA buffer segment address
34       52     Return segment:offset of DMA buffer
35       53     Allocate maximum memory available in system
36       54     Allocate maximum memory available at specified address
37       55     Allocate a segment as specifed in MCB
38       56     Allocate specified memory at specified address
39       57     Free memory starting at a specified address
3A       58             Unallocated
3B       59     Load CMD file into memory
3C       60     Call RSX program
3D       61             Calls 3Dh to 62h are
62       98             unallocated
63       99     Truncate file to the specified random record number
64      100     Create or update a directory label
65      101     Get directory label data byte for specified drive
66      102     Return a file's date/time stamps and password mode
67      103     Create or update a file's extended FCB
68      104     Set internal date and time
69      105     Get internal date and time
6A      106     Set the default password
6B      107     Get the DOS Plus serial number (Not version number)
6C      108     Get/set program return cole
6D      109     Get/set console mode
6E      110     Get/set output delimiter
6F      111     Write a specified block of characters
70      112     Write a specified number of characters to the list device
71      113             Calls 71h to 8Ch are
8C      140             unallocated
8D      141     Delay a specified number of ticks (wait)
8E      142     Relinquish processor to other programs (multitasking)
8F      143     Terminate program (exactly as 0)
90      144             Calls 90h to 92h are
92      146             unallocated
93      147     Detach program from console (enter background)
94      148             Calls 94h to 97h are
97      151             unallocated
98      152     Parse ASCII string and initialise FCB
99      153             Unallocated
9A      154     Get System data area (SYSDAT) address
95      155             Calls 95h to ADh are
AB      171             unallocated
AC      172     Read characters from AUXIN
AD      173     Send characters to AUXOUT
AE      174             Calls AEh to FF are
FF      255             unallocated

INT E0h Function Summary by Operation Type

The BDOS call summary shown below groups functions by operation type. The list is essentially in numerical order within operations, but where two functions complement each other they have been placed together if this does not occur naturally.

It must be remembered that, in CP/M disc formats a directory sub-structure is not supported, nor is file date/time stamping the norm (although this can be initiated by the DOS Plus INIT command). Many of the disc and file handling calls may, therefore, not be appropriate for use with MS-DOS or PC-DOS disc formats.

In CP/M, files are protected or separated from each other by being assigned to a group under different user numbers (0 to 15) rather than by being placed in different directories. In CP/M, media attributes can be set at disc and/or file level which can, even in direct BDOS calls, prevent or restrict unanthorised access to files in several different ways.

Hex      Dec    Function type

Auxiliary character I/O

03      3       Auxiliary input
04      4       Auxiliary output
07      7       Auxiliary input status
08      8       Auxiliary output status
AC      172     Read characters from AUXIN
AD      173     Send characters to AUXOUT

Console Input/Output

01      1       Read a character
02      2       Write a character
06      6       Direct console I/O
09      9       String output
0A      10      Read an edited line
0B      11      Get console status
6D      109     Get/set console mode
6E      110     Get/set output delimiter
6F      111     Write a specified block of characters
93      147     Detach program from console (enter background)

Disc Drive Operations

0D      13      Reset all drives
0E      14      Set default drive
18      24      Return 'Login Vector' for all logged in drives
19      25      Return the default drive ID
1B      27      Get address of disc allocation vectors
1C      28      Set the default drive to read-only
10      29      Get read-only drive vectors
1F      31      Get calling process's default disc DPB address
25      37      Reset the specified drives
27      39      Free specified drives
2E      46      Return unallocated space on the specified drive
30      48      Flush (write) pending internal disc buffers to media
64      100     Create or update a directory label
65      101     Get directory label data byte for specified drive

File Operations

0D      13      Reset all drives
0E      14      Set default drive
18      24      Return 'Login Vector' for all logged in drives
19      25      Return the default drive ID
1B      27      Get address of disc allocation vectors
1C      28      Set the default drive to read-only
10      29      Get read-only drive vectors
1F      31      Get calling process's default disc DPB address
25      37      Reset the specified drives
27      39      Free specified drives
2E      46      Return unallocated space on the specified drive
30      48      Flush (write) pending internal disc buffers to media
64      100     Create or update a directory label
65      101     Get directory label data byte for specified drive

List Device Calls

05      5       Write a character to the list device
70      112     Write a specified number of characters to the list device

Process Management

00      0       Terminate program (exactly as 8Fh)
2F      47      Load and execute program specified DMA buffer
3B      59      Load CMD file into memory
3C      60      Call RSX program
6C      108     Get/set program return code
8D      141     Delay a specified number of ticks (wait)
8E      142     Relinquish processor to other programs (multitask)
8F      143     Terminate program (exactly as 00)

Memory Management

35      53      Allocate maximum memory available in system
36      54      Allocate maximum memory available at specified address
37      55      Allocate a segment as specified in MCB
38      56      Allocate specified memory at specified address
39      57      Free memory starting from a specified address

Time/Date Functions

68      104     Set internal date and time
69      105     Get internal date and time
(NB: Time is in hours and minutes only)

Miscellaneous Functions

0C      12      Get BDOS version number
31      49      Get/set system variable
32      50      Call BIOS (XIOS) directly (See below)
6B      107     Get the DOS Plus serial number (Not version number)
9A      154     Get Sytem data area (SYSDAT) address

INT E0h Function 32h XIOS Subfunctions

Within interrupt E0h is function 32h, which gives another range of subfunctions, direct calls to the XIOS. As usual CL is set to the interrupt function number, are, while DS:DX are used as pointers to the memory location containing the XIOS call parameters

As can be seen, many of the standard CP/M functions are almost identical to the slightly easier to use BDOS functions and hence are of little advantage. The block of functions with values of 80h or greater are peculiar to the XIOS as implemented for Acorn 6502 host systems, while function 80h itself is provided for use within the BDOS and the bootstrap loader.

Hex      Dec    Function type

00       00     Terminate program (Same as BDOS function 0/8Fh)
0l       01     As above
02       02     Check for console input status
03       03     Read character from console
04       04     Write character to console
05       05     Write character to list device
06       06     Write character to auxiliary device
07       07     Read character from auxiliary device
0F       15     Return list device status
10       16          Calls 10h to 14h are
14       20          reserved
15       21     Device initialisation
16       22     Check console output status
17       23          Calls 17h to 7Fh are
7F      127          reserved
80      128     XIOS version (ACORN specific)
81      129     Get tube semaphore
82      130     Release the semaphore
83      131     Select text-graphics
84      132     Update graphics rectangle (B&W)
85      133     Update graphics rectangle (colour) <But see here - YP>
86      134     Get release/update mouse
87      135     Get system error info
88      136     Entry in CLOCK called by WatchDog RSP
89      137     BBC OSBYTE function
8A      138     BBC OSWORD function

< Previous  |  Contents  |  Next >

About the Master 512 | Bibliography