home *** CD-ROM | disk | FTP | other *** search
/ Simtel MSDOS 1992 December / simtel1292_SIMTEL_1292_Walnut_Creek.iso / msdos / sysutl / ddosaid.arc / DOUBLEDO.EQU < prev    next >
Text File  |  1985-12-12  |  8KB  |  175 lines

  1.            PAGE    62,132
  2.            TITLE   DoubleDOS Equates and Interrupt explanations
  3.  
  4.                                   
  5. Dos_Call   EQU     21h             ;DOS Service Interrupt
  6.  
  7.  
  8. ; The following is a list of function calls that DoubleDOS adds to DOS 
  9. ;   These are additional functions available through INT 21H and appear as 
  10. ;   functions E0 hex to EE hex. (calls F0h - FEh are identical) If any of 
  11. ;   these calls to DOS are made when DoubleDOS is NOT running, then no 
  12. ;   function is performed and AL is returned zero by DOS.
  13.  
  14. ; Notes: If your program must run with non PC-DOS Operating Systems then 
  15. ;   calls E0-EE must be used and not F0-FE. Both ranges are functionally 
  16. ;   identical. The term "visible" means "Has keyboard attached." The term
  17. ;   "Invisible" means "No keyboard attached."
  18.  
  19.  
  20. DD_Menu_Control    EQU     0E0h    ;DoubleDOS Menu control functions
  21.  
  22. ; The following are AL values for this service.
  23.  
  24. Switch_Jobs        EQU     01h     ;Exchange Tasks - Visible/Invisible
  25. Resume_Invisible   EQU     73h     ;Resume Invisible job if suspended
  26. Kill_Other_Job     EQU     74h     ;Kill other job
  27. Suspend_Invisible  EQU     75h     ;Suspend Invisible job
  28.  
  29.  
  30. DD_Clear_KBD       EQU     0E1h    ;Clear keyboard buffer for the current
  31.                                    ;  job only. This call does not clear 
  32.                                    ;  the standard input buffer if it is 
  33.                                    ;  not the keyboard.
  34.  
  35.  
  36. DD_Send_Char       EQU     0E2h    ;Send ASCII charachter in AL to other
  37.                                    ;  keyboard buffer. AL returns 0 if 
  38.                                    ;  xfer successful, 1 if buffer is full.
  39.                                    ;  Keyboard buffer is 128 chars.
  40.  
  41.  
  42. DD_Add_Char        EQU     0E3h    ;Add ASCII charachter in AL to keyboard
  43.                                    ;  buffer.  Error return same as the
  44.                                    ;  DD_Send_Char service.
  45.  
  46. ; Programmable redirection of keyboard input can be accomplished by 
  47. ;   using this call in conjunction with function E8 to disable the 
  48. ;   keyboard (this will prevent unexpected user intervention), and 
  49. ;   optionally function E1 to flush unwanted keyboard input.  When 
  50. ;   redirection is completed, the keyboard can be reenabled with 
  51. ;   function E8.
  52.  
  53.  
  54. DD_Status          EQU     0E4h    ;Return current program status in AL
  55.                                    ;  AL = 0  DoubleDOS NOT running
  56.                                    ;  AL = 1  Program is Visible
  57.                                    ;  AL = 2  Program is Invisible
  58.                                    ;  AH = Task Number
  59.  
  60.  
  61. DD_Other_Status    EQU     0E5h    ;Return other program status in AL
  62.                                    ;  AL = 0 No program running
  63.                                    ;  AL = 1 Program is running
  64.                                    ;  AL = 2 Program is suspended
  65.  
  66.  
  67. DD_KBD_Flags       EQU     0E8h    ;Set/reset keyboard control flags by
  68.                                    ;  mask bits in DX. "1" enables, "0"
  69.                                    ;  disables.  On return, DX contains
  70.                                    ;  the previous flags.
  71.  
  72. ; Note: Disabling the Ctrl/Prtsc (Bit 4 = 0) will allow this key sequence
  73. ;   to be intercepted by applications programs.  Disabling any other key
  74. ;   sequence disables those keys completely.
  75.  
  76. ;  AL = 0 Sets flags for this program
  77. ;  AL = 1 Sets flags for other program
  78.  
  79. ;  DX =   Keyboard control flags
  80.  
  81. ;     = 0001 Bit 0 = Menu
  82. ;     = 0002 Bit 1 = Exchange
  83. ;     = 0004 Bit 2 = Entire keyboard enable/disable
  84. ;     = 0008 Bit 3 = Ctrl/C
  85. ;     = 0010 Bit 4 = Crtl/Prtsc
  86. ;     = 0020 Bit 5 = Alt/Erase
  87. ;     = 0040 Bit 6 = Ctrl/Break
  88. ;     = 0080 Bit 7 = Ctrl/Numlock
  89. ;     = 0100 Bit 8 = Shift/Prtsc
  90. ;     = 0200 Bit 0 = (Undefined)
  91. ;     = 0400 Bit 0 = (Undefined)
  92. ;     = 0800 Bit 0 = (Undefined)
  93. ;     = 1000 Bit 0 = (Undefined)
  94. ;     = 2000 Bit 0 = (Undefined)
  95. ;     = 4000 Bit 0 = Cancel key (Clear Keyboard Buffer)
  96. ;     = 8000 Bit 0 = Suspend Key
  97.  
  98.  
  99. SS_Set_Timeshare   EQU     0E9h    ;Set timesharing priority
  100.  
  101. ;  AL = 0 Visible program gets 70% Invisible gets 30% (Default)
  102. ;  AL = 1 Visible program gets 50% Invisible gets 50% of time  
  103. ;  AL = 2 Visible program gets 30% Invisible gets 70% of time  
  104. ;  AL = 3 Top     program gets 70% Bottom    gets 30% of time
  105. ;  AL = 4 Top     program gets 30% Bottom    gets 70% of time
  106.  
  107.  
  108. Timeshare_Off      EQU     0EAh    ;Turn off timesharing, Ctrl/Break,
  109.                                    ;  Ctrl/Numlock and Menu. This service
  110.                                    ;  also performed by INT 0FAh
  111.  
  112. ; The other memory section is suspended by this call.  A request for any
  113. ;   of the funtions disabled will be saved and executed after INT 0FBh is
  114. ;   issued.  Any DOS function call less than 0Dh will automatically 
  115. ;   terminate this mode as if INT 0FBh had been issued.
  116.  
  117.  
  118. Timeshare_On       EQU     0EBh    ;Turn on timesharing, etc.
  119.                                    ;  This service is also performed by
  120.                                    ;  INT 0FBh
  121.  
  122. Display_Address    EQU     0ECh    ;Return current display buffer address
  123.                                    ;  in ES. This service is also performed
  124.                                    ;  by INT 0FCh
  125.  
  126. ; The segment address of the current display buffer is returned in the ES
  127. ;   register. This function is used for programs which do direct screen 
  128. ;   updates, such as 1-2-3. The address returned will be:
  129. ;     B800h - If program is visible on Color Adapter
  130. ;     B000h - If program is visible on Monochrome Adapter
  131. ;     xxxxh - If program is invisible (Address of virtual buffer)
  132.  
  133.  
  134. Give_Other_Time    EQU     0EEh    ;Give time to other task. Thsi service
  135.                                    ;  is also performed by INT 0FEh
  136. ;
  137. ; AL = 0 - 0FFh  : Number of 55ms time intervals to give away.
  138. ;
  139. ; On the next timer interrupt following this call, if the other memory section
  140. ;   is active, it will recieve AL extra 55ms time intervals before the calling
  141. ;   program will recieve another interval.  A loop of these calls will allow
  142. ;   the calling program to give all of it's wasted time to the other memory
  143. ;   section. Programs waiting for keyboard input could do the following:
  144. ;
  145. ;   Keyloop:  mov     AH,1
  146. ;             int     16H          ;Get keyboard status
  147. ;             jnz     Have_One     ;A key was stuck
  148. ;             call    Do_Anything  ;Rest of process loop
  149. ;
  150. ;*  Here is a good place to give some time to the other task
  151. ;
  152. ;             mov     AL,2         ;Give extra 110ms to other task
  153. ;             int     0FEH         ;Other task also gets unused portion
  154. ;                                  ;of current clock cycle
  155. ;             jmp     Keyloop      ;Other task has already run
  156. ;
  157. ; This interrupt will not guarantee that the requested time will actually 
  158. ;   be spent by the other program. If the other program is also "giving 
  159. ;   away time" doing keyboard input, printing etc. then your routine will 
  160. ;   still receive all unused processing time, ie. when the other task does 
  161. ;   int 0FEh it will force an immediate return from the int 0feh in your 
  162. ;   program.  DoubleDOS uses this routine to facilitate overlapped 
  163. ;   processing when waiting for devices to respond.  
  164.  
  165.  
  166. ; DoubleDOS VIDEO ROUTINES (INT 10H): The BIOS replacement video handler 
  167. ;   built into DoubleDOS is Enhanced to provide all features of the IBM PC-
  168. ;   AT video handler including the WRITE STRING function, as well as all 
  169. ;   INT 10H video features built into the IBM TOPVIEW product. These 
  170. ;   features are syntactically identical to their IBM counterparts.  
  171.  
  172.  
  173.  
  174.  
  175.