[Reduction] #44: graph_extmode

This commit is contained in:
nmlgc 2014-08-15 16:11:51 +02:00
parent a313ae5d78
commit a033b347fc
14 changed files with 144 additions and 749 deletions

View File

@ -1,6 +1,6 @@
; *Not* the original file. Changes include:
; * replacement of DATASIZE and CODESIZE with TASM's @DataSize and @CodeSize
; variables
; * a rewrite of the memory model conditional branches at the beginning to
; refer to TASM's @MODEL symbol
; * removal of the FUNC and ENDFUNC macros, which don't work with TASM's
; strict alignment constraints. In turn, this means that we also need to
; edit all source code files to not use these macros.
@ -25,22 +25,19 @@
; 93/ 2/12 COMPACTMODEL, MEDIUMMODEL
.list
IFDEF NEARMODEL
IF @MODEL LE 2
CALLMODEL equ NEAR
RETSIZE EQU 1
DATASIZE EQU 1
ENDIF
IFDEF COMPACTMODEL
ELSEIF @MODEL EQ 3
CALLMODEL equ NEAR
RETSIZE EQU 1
DATASIZE EQU 2
ENDIF
IFDEF MEDIUMMODEL
ELSEIF @MODEL EQ 4
CALLMODEL equ FAR
RETSIZE EQU 2
DATASIZE EQU 1
ENDIF
IFDEF FARMODEL
ELSEIF @MODEL EQ 5
CALLMODEL equ FAR
RETSIZE EQU 2
DATASIZE EQU 2
@ -86,7 +83,7 @@ lab dw ?
ENDM
IF @DataSize EQ 1
IF DATASIZE EQ 2
_push MACRO reg
push reg
ENDM
@ -159,7 +156,7 @@ ENDIF
; _call: かならず同一セグメントにあると判っているルーチンをcallする
; ときに使用するマクロ (94/1/1追加)
IF @CodeSize EQ 1
IF RETSIZE EQ 2
_call MACRO place
push CS
call near ptr place

View File

@ -0,0 +1,106 @@
; master library - 9821
;
; Description:
; 9821拡張グラフィックモードの設定取得
;
; Function/Procedures:
; unsigned graph_extmode( unsigned modmask, unsigned bhal ) ;
;
; Parameters:
; modmask:上位8bit: BHを操作するビットマスク
; modmask:下位8bit: ALを操作するビットマスク
; bhal 上位8bit: BHに設定する値(modmaskに対応したビットのみ有効)
; 下位8bit: ALに設定する値(modmaskに対応したビットのみ有効)
;
; ビットの内容:
; AL b7 b6 b5 b4 b3 b2 b1 b0
; ++- 0 ノンインターレース
; 1 インターレース
; ++-++------- 00 15.98kHz
; 10 24.83kHz
; 11 31.47kHz
; BH b7 b6 b5 b4 b3 b2 b1 b0
; || || ++-++- 00 20行
; || || 01 25行
; || || 10 30行
; ++-++------------- 00 640x200(UPPER)
; 01 640x200(LOWER)
; 10 640x400
; 11 640x480
;
;
; Returns:
; 実際に設定した値(almod=bhmod=0ならば取得した値)
; (上位8bit=BH, 下位8bit=ALね)
;
; Binding Target:
; Microsoft-C / Turbo-C / Turbo Pascal
;
; Running Target:
; PC-9801/9821, ただし9821でないと実行しても何もしないで 0 を返す。
;
; Requiring Resources:
; CPU: V30
;
; Notes:
;
;
; Assembly Language Note:
;
;
; Compiler/Assembler:
; TASM 3.0
; OPTASM 1.6
;
; Author:
; 恋塚昭彦
;
; Revision History:
; 94/ 1/ 8 Initial: grpextmd.asm/master.lib 0.22
graph_extmode proc ; graph_extmode() {
xor AX,AX
mov ES,AX
test byte ptr ES:[045ch],40h
jz short G31_NOTMATE
;
modmask = (RETSIZE+1)*2
bhal = (RETSIZE+0)*2
mov BX,SP
mov CX,SS:[BX+modmask]
mov DX,SS:[BX+bhal]
mov AH,31h
int 18h ; 拡張グラフアーキテクチャモードの取得
mov AH,BH
jcxz short EXT_DONE ; modmask=0だったら読み取って終わり
and DX,CX
not CX
and AX,CX
or AX,DX
mov CX,AX
mov BH,AH
mov AH,30h ; 拡張グラフアーキテクチャモードの設定
int 18h
test TextShown,1
jz short TEXT_SHOWN
mov AH,0ch
int 18h ; テキスト画面の表示
TEXT_SHOWN:
test CL,1
jz short NO_SETAREA
mov AH,0eh ; 一つの表示領域の設定
xor DX,DX
int 18h
NO_SETAREA:
test byte ptr ES:[0711h],1
jz short CURSOR_HIDDEN
mov AH,11h ; カーソルの表示
int 18h
CURSOR_HIDDEN:
mov AX,CX
EXT_DONE:
G31_NOTMATE:
ret 4
endp ; }

View File

@ -18,6 +18,7 @@
locals
include libs/BorlandC/RULES.ASI
include libs/master.lib/func.inc
; ===========================================================================
@ -3782,66 +3783,7 @@ sub_1614 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_166A proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_16BD
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_16BD
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_16A4
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_16A4:
test cl, 1
jz short loc_16AF
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_16AF:
test es:byte_711, 1
jz short loc_16BB
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_16BB:
mov ax, cx
locret_16BD:
retf 4
sub_166A endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5906,7 +5848,7 @@ sub_2740 proc far
push ax
push ax
push cs
call near ptr sub_166A
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_1E2C6, 33FFh

View File

@ -18,6 +18,7 @@
locals
include libs/BorlandC/RULES.ASI
include libs/master.lib/func.inc
; ===========================================================================
@ -3256,66 +3257,7 @@ sub_1276 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_12CC proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_131F
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_131F
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1306
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1306:
test cl, 1
jz short loc_1311
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1311:
test byte ptr es:loc_70E+3, 1
jz short loc_131D
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_131D:
mov ax, cx
locret_131F:
retf 4
sub_12CC endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5296,7 +5238,7 @@ sub_233E proc far
push ax
push ax
push cs
call near ptr sub_12CC
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_D6D8, 33FFh

View File

@ -18,6 +18,7 @@
locals
include libs/BorlandC/RULES.ASI
include libs/master.lib/func.inc
; ===========================================================================
@ -2988,66 +2989,7 @@ sub_1290 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_12E6 proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_1339
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_1339
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1320
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1320:
test cl, 1
jz short loc_132B
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_132B:
test es:byte_711, 1
jz short loc_1337
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1337:
mov ax, cx
locret_1339:
retf 4
sub_12E6 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5332,7 +5274,7 @@ sub_2596 proc far
push ax
push ax
push cs
call near ptr sub_12E6
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_DBA2, 33FFh

View File

@ -18,6 +18,7 @@
locals
include libs/BorlandC/RULES.ASI
include libs/master.lib/func.inc
; ===========================================================================
@ -3387,66 +3388,7 @@ sub_14E4 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_153A proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_158D
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_158D
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1574
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1574:
test cl, 1
jz short loc_157F
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_157F:
test byte ptr es:loc_710+1, 1
jz short loc_158B
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_158B:
mov ax, cx
locret_158D:
retf 4
sub_153A endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5288,7 +5230,7 @@ sub_20FC proc far
push ax
push ax
push cs
call near ptr sub_153A
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_1DB02, 33FFh

View File

@ -18,6 +18,7 @@
locals
include libs/BorlandC/RULES.ASI
include libs/master.lib/func.inc
; ===========================================================================
@ -2484,66 +2485,7 @@ sub_EAC endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_F02 proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_F55
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_F55
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_F3C
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_F3C:
test cl, 1
jz short loc_F47
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_F47:
test byte ptr es:loc_710+1, 1
jz short loc_F53
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_F53:
mov ax, cx
locret_F55:
retf 4
sub_F02 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -4519,7 +4461,7 @@ sub_1F6E proc far
push ax
push ax
push cs
call near ptr sub_F02
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_EC36, 33FFh

View File

@ -18,6 +18,7 @@
locals
include libs/BorlandC/RULES.ASI
include libs/master.lib/func.inc
; ===========================================================================
@ -2874,66 +2875,7 @@ sub_1186 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_11DC proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_122F
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_122F
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1216
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1216:
test cl, 1
jz short loc_1221
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1221:
test byte ptr es:loc_70F+2, 1
jz short loc_122D
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_122D:
mov ax, cx
locret_122F:
retf 4
sub_11DC endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5080,7 +5022,7 @@ sub_22CA proc far
push ax
push ax
push cs
call near ptr sub_11DC
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_DD92, 33FFh

View File

@ -657,7 +657,6 @@ loc_459:
xor ax, ax
loc_45B:
; sub_1CF4+4r
jmp short loc_464
; ---------------------------------------------------------------------------
nop
@ -4107,66 +4106,7 @@ sub_1CD0 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_1CF4 proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_1D47
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_1D47
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1D2E
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1D2E:
test cl, 1
jz short loc_1D39
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1D39:
test byte ptr es:loc_711, 1
jz short loc_1D45
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1D45:
mov ax, cx
locret_1D47:
retf 4
sub_1CF4 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5202,7 +5142,7 @@ sub_236C proc far
push ax
push ax
push cs
call near ptr sub_1CF4
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_21AB2, 33FFh

View File

@ -655,7 +655,6 @@ loc_459:
xor ax, ax
loc_45B:
; sub_1218+4r
jmp short loc_464
; ---------------------------------------------------------------------------
nop
@ -2610,66 +2609,7 @@ sub_11C2 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_1218 proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_126B
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_126B
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1252
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1252:
test cl, 1
jz short loc_125D
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_125D:
test byte ptr es:loc_711, 1
jz short loc_1269
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1269:
mov ax, cx
locret_126B:
retf 4
sub_1218 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -4406,7 +4346,7 @@ sub_2110 proc far
push ax
push ax
push cs
call near ptr sub_1218
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_E930, 33FFh

View File

@ -655,7 +655,6 @@ loc_459:
xor ax, ax
loc_45B:
; sub_15C2+4r
jmp short loc_464
; ---------------------------------------------------------------------------
nop
@ -3090,66 +3089,7 @@ sub_156C endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_15C2 proc far
xor ax, ax
mov es, ax
assume es:seg000
test byte ptr es:loc_45B+1, 40h
jz short locret_1615
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_1615
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_15FC
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_15FC:
test cl, 1
jz short loc_1607
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1607:
test byte ptr es:loc_711, 1
jz short loc_1613
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1613:
mov ax, cx
locret_1615:
retf 4
sub_15C2 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5024,7 +4964,7 @@ sub_2552 proc far
push ax
push ax
push cs
call near ptr sub_15C2
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_FB94, 33FFh

View File

@ -665,7 +665,6 @@ loc_454:
; ---------------------------------------------------------------------------
db 89h
byte_45C db 87h
; sub_1E86+4r
db 72h, 3, 0A1h, 72h, 3, 0Bh, 6, 74h, 3, 5, 2 dup(0FFh)
db 1Bh, 0C0h, 3Bh, 6, 70h, 3, 74h, 29h, 0A3h, 70h, 3, 77h
db 26h, 0FAh, 0B0h, 0Bh, 0E6h, 70h, 0A0h, 77h, 3, 0E6h
@ -4175,66 +4174,7 @@ sub_1E62 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_1E86 proc far
xor ax, ax
mov es, ax
assume es:seg000
test es:byte_45C, 40h
jz short locret_1ED9
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_1ED9
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_1EC0
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1EC0:
test cl, 1
jz short loc_1ECB
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1ECB:
test byte ptr es:loc_710+1, 1
jz short loc_1ED7
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_1ED7:
mov ax, cx
locret_1ED9:
retf 4
sub_1E86 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -5400,7 +5340,7 @@ sub_260E proc far
push ax
push ax
push cs
call near ptr sub_1E86
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_2109A, 33FFh

View File

@ -666,7 +666,6 @@ loc_454:
; ---------------------------------------------------------------------------
db 89h
byte_45C db 87h
; sub_1392+4r
db 0BEh, 1, 0A1h, 0BEh, 1, 0Bh, 6, 0C0h, 1, 5, 2 dup(0FFh)
db 1Bh, 0C0h, 3Bh, 6, 0BCh, 1, 74h, 29h, 0A3h, 0BCh, 1
db 77h, 26h, 0FAh, 0B0h, 0Bh, 0E6h, 70h, 0A0h, 0C3h, 1
@ -2802,66 +2801,7 @@ sub_133C endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_1392 proc far
xor ax, ax
mov es, ax
assume es:seg000
test es:byte_45C, 40h
jz short locret_13E5
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_13E5
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_13CC
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_13CC:
test cl, 1
jz short loc_13D7
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_13D7:
test byte ptr es:loc_710+1, 1
jz short loc_13E3
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_13E3:
mov ax, cx
locret_13E5:
retf 4
sub_1392 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -4734,7 +4674,7 @@ sub_2320 proc far
push ax
push ax
push cs
call near ptr sub_1392
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_10606, 33FFh

View File

@ -665,7 +665,6 @@ loc_454:
; ---------------------------------------------------------------------------
db 89h
byte_45C db 87h
; sub_12A6+4r
db 0D4h, 4, 0A1h, 0D4h, 4, 0Bh, 6, 0D6h, 4, 5, 2 dup(0FFh)
db 1Bh, 0C0h, 3Bh, 6, 0D2h, 4, 74h, 29h, 0A3h, 0D2h, 4
db 77h, 26h, 0FAh, 0B0h, 0Bh, 0E6h, 70h, 0A0h, 0D9h, 4
@ -2565,66 +2564,7 @@ sub_1250 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_12A6 proc far
xor ax, ax
mov es, ax
assume es:seg000
test es:byte_45C, 40h
jz short locret_12F9
mov bx, sp
mov cx, ss:[bx+6]
mov dx, ss:[bx+4]
mov ah, 31h ; '1'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
mov ah, bh
jcxz short locret_12F9
and dx, cx
not cx
and ax, cx
or ax, dx
mov cx, ax
mov bh, ah
mov ah, 30h ; '0'
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
test TextShown, 1
jz short loc_12E0
mov ah, 0Ch
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_12E0:
test cl, 1
jz short loc_12EB
mov ah, 0Eh
xor dx, dx
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_12EB:
test byte ptr es:loc_710+1, 1
jz short loc_12F7
mov ah, 11h
int 18h ; TRANSFER TO ROM BASIC
; causes transfer to ROM-based BASIC (IBM-PC)
; often reboots a compatible; often has no effect at all
loc_12F7:
mov ax, cx
locret_12F9:
retf 4
sub_12A6 endp
include libs/master.lib/graph_extmode.asm
; =============== S U B R O U T I N E =======================================
@ -4412,7 +4352,7 @@ sub_2162 proc far
push ax
push ax
push cs
call near ptr sub_12A6
call near ptr graph_extmode
and ax, 0Ch
cmp ax, 0Ch
mov word_F7FC, 33FFh