home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Simtel MSDOS 1992 December
/
simtel1292_SIMTEL_1292_Walnut_Creek.iso
/
msdos
/
asmutl
/
ovl301.arc
/
MULTEST.ASM
< prev
next >
Wrap
Assembly Source File
|
1989-01-11
|
1KB
|
52 lines
DOSSEG
.MODEL large
.STACK 100h
PUBLIC messa,messb,messc,messd
EXTRN multa:PROC,multb:PROC,multc:PROC,multd:PROC
.CODE
start:
mov ax,dgroup
mov ds,ax
mov dx,offset message
mov ah,9
int 21h
mov ah,1 ; keyboard input with echo
int 21h
and al,0dfh ; upshift lowercase chars
cmp al,65 ; 'A' keypress
jne nota
call multa
jmp short start
nota:
cmp al,66 ; 'B' keypress
jne notb
call multb
jmp short start
notb:
cmp al,67 ; 'C' keypress
jne notc
call multc
jmp short start
notc:
cmp al,68 ; 'D' keypress
jne notd
call multd
jmp short start
notd:
cmp al,81 ; 'Q'
jne start ; invalid keypress, reloop
mov ax,4c00h ; terminate with errorlevel 0
int 21h
.DATA
message db 13,10,"Press A,B,C,D or Q to quit: ",'$'
messa db 13,10,13,10,"Now in process A",13,10,'$'
messb db 13,10,13,10,"Now in process B",13,10,'$'
messc db 13,10,13,10,"Now in process C",13,10,'$'
messd db 13,10,13,10,"Now in process D",13,10,'$'
END start