What does "int 21h" mean in Assembly?

107,352

Solution 1

int 21h means, call the interrupt handler 0x21 which is the DOS Function dispatcher. the "mov ah,01h" is setting AH with 0x01, which is the Keyboard Input with Echo handler in the interrupt. See:

http://spike.scu.edu.au/~barry/interrupts.html

Solution 2

INT 21H will generate the software interrupt 0x21 (33 in decimal), causing the function pointed to by the 34th vector in the interrupt table to be executed, which is typically an MS-DOS API call.

Share:
107,352
BOSS
Author by

BOSS

Updated on July 09, 2022

Comments

  • BOSS
    BOSS almost 2 years

    I'm new to learning assembly language, and I'm wondering what the command int 21h means. For example:

     mov ah,01h
     int 21h
    

    Which should read a key from the user.