DOS API

Most of DOS API calls are invoked using software interrupt INT 21H. In most cases AH register sets to function number.

DOS Interrupts

Interrupt vector	Description	Version	Notes
20H	Terminate program	1.0+	Implemented in DOS kernel
21H	Main DOS API	1.0+	Implemented in DOS kernel
22H	Program terminate address	1.0+	Return address in calling program
23H	Control-C handler address	1.0+	Default handler is in the command shell (usually COMMAND.COM)
24H	Critical error handler address	1.0+	Default handler is in the command shell (usually COMMAND.COM)
25H	Absolute disk read	1.0+	Implemented in DOS kernel, enhanced in DOS 3.31 to support up to 2 GB partitions
26H	Absolute disk write	1.0+	Implemented in DOS kernel, enhanced in DOS 3.31 to support up to 2 GB partitions
27H	Terminate and stay resident	1.0+	Implemented in COMMAND.COM in DOS 1.0, DOS kernel in DOS 2.0+
28H	Idle callout	2.0+	Called by DOS kernel when waiting for input
29H	Fast console output	2.0+	Implemented by the builtin console device driver or a replacement driver like ANSI.SYS
2AH	Networking and critical section	3.0+	Called by DOS kernel to interface with networking software
2EH	Reload transient	2.0+	Implemented in COMMAND.COM
2FH	Multiplex	3.0+	Implemented in DOS kernel and various programs (PRINT, MSCDEX, DOSKEY, APPEND, etc.) depending on subfunction number