moin,
ich habe ein Problem beim auslesen des Modus Infos unter Vesa.
hier mal mein Code:
mov ax, 0x4F00
mov di, VbeInfoBlock
int 0x10
.1:
mov cx, 0x114
mov ax, 0x4F01
mov di, ModeInfoBlock
int 0x10
mov dx, [XResolution]
cli
hlt
PS: auch mit anderen Modusen versucht
auf jeden fall ist dx = 0x00 .... obwohl es 0x320 sein sollte (800x600) ..
wieso ist das so?
achja hier noch meine Struktur:
;===== Info Block =====;
VbeInfoBlock:
VbeSignature db "VBE2" ; VBE Signature
VbeVersion dw 0300h ; VBE Version
OemStringPtr dd 0 ; VbeFarPtr to OEM String
Capabilities dd 0 ; Capabilities of graphics controller
VideoModePtr dd 0 ; VbeFarPtr to VideoModeList
TotalMemory dw 0 ; Number of 64kb memory blocks
OemSoftwareRev dw 0 ; VBE implementation Software revision
OemVendorNamePtr dd 0 ; VbeFarPtr to Vendor Name String
OemProductNamePtr dd 0 ; VbeFarPtr to Product Name String
OemProductRevPtr dd 0 ; VbeFarPtr to Product Revision String
.Reserved: times 222 db 0 ; Reserved for VBE implementation scratch
.OemData: times 256 db 0 ; Data Area for OEM Strings
;===== Mode Info Block =====;
ModeInfoBlock:
ModeAttributes dw 0 ; mode attributes
WinAAttributes db 0 ; window A attributes
WinBAttributes db 0 ; window B attributes
WinGranularity dw 0 ; window granularity
WinSize dw 0 ; window size
WinASegment dw 0 ; window A start segment
WinBSegment dw 0 ; window B start segment
WinFuncPtr dd 0 ; real mode pointer to window function
BytesPerScanLine dw 0 ; bytes per scan line
XResolution dw 0 ; horizontal resolution in pixels or characters3
YResolution dw 0 ; vertical resolution in pixels or characters
XCharSize db 0 ; character cell width in pixels
YCharSize db 0 ; character cell height in pixels
NumberOfPlanes db 0 ; number of memory planes
BitsPerPixel db 0 ; bits per pixel
NumberOfBanks db 0 ; number of banks
MemoryModel db 0 ; memory model type
BankSize db 0 ; bank size in KB
NumberOfImagePages db 0 ; number of images
.Reserved db 1 ; reserved for page function
RedMaskSize db 0 ; size of direct color red mask in bits
RedFieldPosition db 0 ; bit position of lsb of red mask
GreenMaskSize db 0 ; size of direct color green mask in bits
GreenFieldPosition db 0 ; bit position of lsb of green mask
BlueMaskSize db 0 ; size of direct color blue mask in bits
BlueFieldPosition db 0 ; bit position of lsb of blue mask
RsvdMaskSize db 0 ; size of direct color reserved mask in bits
RsvdFieldPosition db 0 ; bit position of lsb of reserved mask
DirectColorModeInfo db 0 ; direct color mode attributes
PhysBasePtr dd 0 ; physical address for flat memory frame buffer
.Reserved1 dd 0 ; Reserved - always set to 0
.Reserved2 dw 0 ; Reserved - always set to 0
LinBytesPerScanLine dw 0 ; bytes per scan line for linear modes
BnkNumberOfImagePages db 0 ; number of images for banked modes
LinNumberOfImagePages db 0 ; number of images for linear modes
LinRedMaskSize db 0 ; size of direct color red mask (linear modes)
LinRedFieldPosition db 0 ; bit position of lsb of red mask (linear modes)
LinGreenMaskSize db 0 ; size of direct color green mask (linear modes)
LinGreenFieldPosition db 0 ; bit position of lsb of green mask (linear modes)
LinBlueMaskSize db 0 ; size of direct color blue mask (linear modes)
LinBlueFieldPosition db 0 ; bit position of lsb of blue mask (linear modes)
LinRsvdMaskSize db 0 ; size of direct color reserved mask (linear modes)
LinRsvdFieldPosition db 0 ; bit position of lsb of reserved mask (linear modes)
MaxPixelClock dd 0 ; maximum pixel clock (in Hz) for graphics mode
.Reserved3: times 189 db 0 ; remainder of ModeInfoBlock