flat assembler
Message board for the users of flat assembler.
Index
> DOS > how to change svga refresh rate at a vesa 3.0 video card |
Author |
|
Matrix 09 Feb 2005, 20:53
hello
sorry i have not implemented these yet, i was writing a modeinfo prog for a week, but i have attached the vesa part from ralph brown interrupt list you have to set the pixel clock, horizontal, vertical synch start end, and the refresh rate in VBE CRTC Information Block
Last edited by Matrix on 11 Feb 2005, 21:51; edited 1 time in total |
|||||||||||
09 Feb 2005, 20:53 |
|
cylo 10 Feb 2005, 09:07
download didnt work.
|
|||
10 Feb 2005, 09:07 |
|
cylo 11 Feb 2005, 15:46
|
|||
11 Feb 2005, 15:46 |
|
Matrix 11 Feb 2005, 21:53
there was an interesting error in my posting :/
but its fixed, i have uploaded it again |
|||
11 Feb 2005, 21:53 |
|
cylo 21 Feb 2005, 07:14
hello again!
i have got some code but its writtn for masm. therefore i got some compiling errors out of fasm. most i solved by myselfe but with one i need your help. Code: CRTC DW 1088 ; horizontal Total in Pixel HORIANF DW 860 ; horizontal Sync-Start in Pixel HORIEND DW 18 ; horizontal Sync-End in Pixel VERTOTA DW 653 ; vertical Total in Lines VERTANF DW 600 ; vertical Sync-Start in Lines VERTEND DW 47 ; vertical Sync-End in Lines DOIFLAG DB 04h ; Flag (interlaced,doubleScan,polarity) PIXCLOC DD 55549000 ; Pixel clock in hz REFRATE DW 8500 ; Refresh-Rate in 0.01 hz Video_Mode = 115h+4000h+800h mov ax, 4F0Bh ; get/set Pixel-Clock xor bl, bl ; get mov ecx, PIXCLOC mov dx, Video_Mode int 10h cmp ax, 4Fh jnz ERROR mov [PIXCLOC], ecx xor eax, eax mov ax, CRTC ; horizontal total xor ebx, ebx mov bx, VERTOTA ; vertikal total mul ebx mov ebx, eax mov eax, ecx ; pixelclock mov esi, 10 xor edx, edx div esi xor edx, edx div ebx mov [REFRATE], ax ; RefreshRate=Pixelclock/(HTotal*Vtotal) mov ax, 4F02h ; set vesa-video-mode mov bx, Video_Mode mov di, OFFSET CRTC ; own timing int 10h cmp ax, 4Fh jnz ERROR error is line Code: mov di, OFFSET CRTC ; own timing i realy have no idea to make this work. thx so far cylo |
|||
21 Feb 2005, 07:14 |
|
vid 21 Feb 2005, 09:01
just rewrite it to
Code: mov bx,[Videomode] mov cx,CRTC but there may be more such problems in code, because this is not FASM code |
|||
21 Feb 2005, 09:01 |
|
cylo 23 Feb 2005, 16:05
damn i am to busy to get this thing work! i will pay for a working fasm code which i can include in borland c++ 3.1 dos!!! ... or any other solution ^^
i still need to change crtc refresh rate (to >60Hz) in svga mode (640x480,...) which is initialized with svga256.bgi. (borland c++ 3.1 dos compiler) on a Vesa 3.0 compatible gpu. please contact me at lars [at(@)] mentze [dot(.)] de ! |
|||
23 Feb 2005, 16:05 |
|
Matrix 25 Feb 2005, 05:06
hello cylo
sorry for just helping in indirect way, but i have some to do ... i did this search on google and found VESA BIOS EXTENSION (VBE) Core Functions Standard(pdf) btw .: pixel clock has to be set correctly, = horizontal pixels * vertical pixels * refresh frequency, in some cases the refresh rate you set is ignored (not sure in these parts) i have not read this doc yet, but you should |
|||
25 Feb 2005, 05:06 |
|
cylo 25 Feb 2005, 08:45
i have allready read the doc.
but i am not so into assambler so it takes a lot of time for me to get this all work. and i have to do a lot of things too... btw the code above descibes how to set pixel clock correctly. 1. calc the pixelclock with gtf formula 2. send requested pixelclock and vidmode to gpu 3. get normalized pixelclock 4. calc refresh rates with normalized pixelclock again i think my main problem is how to get a fasm code into borland c++ 3.1. i realy have no idea about the syntax how to transmit variables and so on.... |
|||
25 Feb 2005, 08:45 |
|
Matrix 25 Feb 2005, 15:16
your c++ documentation should describe how are variables pssed to a procedure, it should be something like EBP+4 EBP+8 EBP+12 EBP+16
DWORD PARAMERERS which you can access like mov eax,[EBP+4] |
|||
25 Feb 2005, 15:16 |
|
cylo 04 Mar 2005, 11:11
i somehow figuered it out but now:
LINKING Refresh.exe Linker Error: 32-Bit record encoutered in module getn.asm ... is it difficult to code a trs which is checking vese mode change? |
|||
04 Mar 2005, 11:11 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.