Category : Alternate Operating Systems - Quarterdeck DesqView, CP/M, etc
Archive   : DDOS_AID.ZIP
Filename : FLIPSTAT.ASM

 
Output of file : FLIPSTAT.ASM contained in archive : DDOS_AID.ZIP

PAGE 62,132
Title DoubleDOS Utility: Other Partition Status

CR EQU 0Dh ;ASCII Carriage Return
LF EQU 0Ah ;ASCII Line Feed
$ EQU 24h ;String termination charachter

Dos_Call EQU 21h
Terminate_Process EQU 4Ch
Put_String EQU 09h
DD_Other_Status EQU 0E5h

Code_Seg SEGMENT
ASSUME cs:Code_Seg,ds:Code_Seg,es:Code_Seg
ORG 0100h
Main PROC NEAR

mov ah,Put_String ;Display program info
mov dx,OFFSET Prog_Info
int Dos_Call

mov ah,DD_Other_Status ;Get DoubleDOS status of
int Dos_Call ; the current partition
mov Stat_Byte,al

or al,00110000b ;convert binary integer
mov Stat_Var,al ; to ASCII and output
mov ah,Put_String
mov dx,OFFSET Stat_Prn ;Output Status
int Dos_Call

mov ah,Put_String ;Errorlevel Message
mov dx,OFFSET Finished
int Dos_Call

mov al,Stat_Byte ;Errorlevel returned
mov ah,Terminate_Process ; in AL
int Dos_Call

Stat_Byte DB ?

Prog_Info DB CR,LF,'DoubleDOS Utility - by Chris M. Magyar'
DB ' - 12/15/85',CR,LF,CR,LF
DB 'Status : 0 - No program runnning.',CR,LF
DB ' 1 - Program is running.',CR,LF
DB ' 2 - Program is suspended.',CR,LF,CR,LF,$

Stat_Prn DB 'Current Partition Status : '
Stat_Var DB ?,CR,LF,$

Finished DB CR,LF,'Status is returned via ERRORLEVEL.',CR,LF,$

Main ENDP
Code_Seg ENDS
END Main