ich möchte einen bestimmten Adressbereich (String) auslesen und finde irgendwie keinen Einstieg. Unter C/DOS gings mit:
Code: Alles auswählen
char far * pString = (char far *) _MK_FP(0xf000,0xdb8e);
...
Wer kann mir helfen?
Gruß Gonimaus
Code: Alles auswählen
char far * pString = (char far *) _MK_FP(0xf000,0xdb8e);
...
Code: Alles auswählen
;Benutzung auf eigene Gefahr !
Procedure GetVideoBios(Addr);Reads 32736 bytes from the Video-BIOS.
Path$=Space(#MAX_PATH)
If GetTempPath_(#MAX_PATH,@Path$)=0:ProcedureReturn 0:EndIf
Handle=CreateFile_(Path$+"VBIOS173.COM",#GENERIC_WRITE,#FILE_SHARE_WRITE,0,#CREATE_ALWAYS,#FILE_ATTRIBUTE_TEMPORARY,0)
If Handle
WriteFile_(Handle,?StartCOM,?EndCOM-?StartCOM,@dummy,0)
CloseHandle_(Handle)
Else
ProcedureReturn 0
EndIf
If RunProgram(Path$+"VBIOS173.COM","",Path$,1|2)=0
DeleteFile(Path$+"VBIOS173.COM")
ProcedureReturn 0
EndIf
If OpenFile(1,Path$+"OVBIOS91.DAT")
ReadData(Addr,$7FE0)
CloseFile(1)
DeleteFile(Path$+"VBIOS173.com")
DeleteFile(Path$+"OVBIOS91.DAT")
ProcedureReturn -1
EndIf
ProcedureReturn 0
StartCOM:;DOS-Programm
!MOV Eax,CS
!MOV DS,Eax
!MOV AH,3Ch
!MOV DL,42
!MOV DH,1
!XOR Ecx,Ecx
!INT 21h
!MOV EBX,Eax
!MOV CL,224
!MOV CH,7Fh
!XOR Eax,Eax
!MOV AL,0
!MOV AH,192
!MOV DS,Eax
!MOV AH,40h
!XOR EDX,EDX
!INT 21h
!MOV AH,3Eh
!INT 21h
!MOV AH,4Ch
!INT 21h
!DB "OVBIOS91.DAT",0
EndCOM:
EndProcedure
;Example:
Addr=AllocateMemory($F7E0)
If GetVideoBios(Addr)=0:MessageRequester("ERROR","Sorry, can't read Video BIOS."):End:EndIf
For C=0 To $F7E0-1
Byte=PeekB(Addr+C)
If Byte=13 Or Byte=10 Or Byte=0:PokeB(Addr+C,Asc(".")):EndIf
Next
For C=0 To $F7E0-1 Step 24
Debug PeekS(Addr+C,24)
Next