KEYBOARD CONTROL
Aim
To write an assembly language program to read a key code and scan from keyboard.
Program
Code segment
Assume cs: code , ds:code
Org 1000h
Mov si,1200h
Mov ah,00h ; bios call for key status read
Int 16h
Mov [si] , ah ; store the key code
Inc si
Mov [si], ah ; store the scan code
Mov ah, 4ch ; dos call for program termination
Int 21h
Code ends
End
Result:
Thus keyboard, display control and file manipulation program are executed by using BIOS/DOS call.
0 comments:
Post a Comment