home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
magazine
/
drdobbs
/
ddjcompr
/
hstest
/
lib
/
bios.asm
next >
Wrap
Assembly Source File
|
1990-11-02
|
1KB
|
68 lines
NAME bios
include tomlib.equ
; Subroutine fuer display-utilities von C aus
;-----------------------------------------------------
; bios(intnum,ax,bx,cx,dx,es:bp) returns ax,dx
;------------------------------------------------------
DGROUP GROUP CONST, _BSS, _DATA
ASSUME DS: DGROUP, SS: DGROUP
BIOS_SEGMENT SEGMENT AT 0
defpub macro NAME,LOCATION
org LOCATION
NAME label byte
public NAME
endm
defpub _BIOS_SHIFT_STATUS,0417h
BIOS_SEGMENT ENDS
_DATA SEGMENT public word
public _BIOS_FLAGS
_BIOS_FLAGS db 0
_DATA ENDS
TEXTSEGMENT
PUBPROC _BIOS
;------------------------------------------------------------------------------
push bp
mov bp,sp
push si
push di
mov ax,(4+SPOFF)[bp]
mov byte ptr cs:[_PATCH_BIOS_INT],al ; modify interrupt number !!!
jmp $+2 ; flush prefetch queue !!! (486)
mov ax,(6+SPOFF)[bp]
mov bx,(8+SPOFF)[bp]
mov cx,(10+SPOFF)[bp]
mov dx,(12+SPOFF)[bp]
public _PATCH_BIOS_INT ; int 0ffh
db 0cdh
_PATCH_BIOS_INT:
db 0ffh
push ax
lahf
mov _BIOS_FLAGS,ah
pop ax
pop di
pop si
pop bp
ret
;------------------------------------------------------------------------------
_BIOS endp
TEXTEND
end