You are on page 1of 1

; Clear screen by resetting the video mode

mov ah, 0fh ; function - get video mode


int 10h
push ax ; save number of columns
push bx ; save page number
mov ah, 0 ; function - set video mode
int 10h
; Set cursor to right corner
pop bx ; restore page number
pop dx ; restore number of columns
mov dl, dh
dec dl
mov dh, 0 ; first line
push bx ; save page number
mov ah, 2 ; function - set cursor
int 10h
; Display any number
pop bx ; restore page number
mov al, '7' ; number 7
mov bl, 0f2h ; attribute = green/white
mov cx, 1 ; print once
mov ah, 9 ; function - print character
int 10h

You might also like