flat assembler
Message board for the users of flat assembler.

Index > MenuetOS > S3 trio VESA bug

Author
Thread Post new topic Reply to topic
compilax



Joined: 18 Feb 2004
Posts: 56
compilax 03 Oct 2004, 04:35
I now have another computer which i plan on using for MenuetOS (rather than rebooting all the time between windows and menuet on this one), but only the VGA modes will work properly. VESA 1.2 640x480, 800x600 and 1024xsomething partially work, but only the top [about 400 pixels, seems to vary a bit between mode] of the screen are shown, then the bottom part of the screen is a repeat of part of the top. in 640x480, it is almost useable, because i can see most of the screen, but 640x480 is small enough as it is. The graphics are on the motherboard, S3 trio 32 or 64 (not sure). I remember seeing a S3 patch a while ago, but i can't find it anywhere and it probably wont work with newer kernels. Any ideas?

PS: the VGA modes work fine, but in 640x480, the main problem is that one can't see the cursor in tinypad. I might take a look at the source and make the cursor another colour (i mean the indicator of where you are at in the text file, not the mouse cursor).

Thanks in advance, Compilax.
Post 03 Oct 2004, 04:35
View user's profile Send private message Visit poster's website MSN Messenger Reply with quote
DennisCGc



Joined: 03 May 2004
Posts: 24
Location: Zoetermeer, The Netherlands
DennisCGc 03 Oct 2004, 11:00
You know, I have the same problem too...
It looks like the some parts will overlap each other (AFAIK)..

I indeed would like to see a patch too....
Post 03 Oct 2004, 11:00
View user's profile Send private message MSN Messenger Reply with quote
Wildwest



Joined: 13 Sep 2004
Posts: 100
Location: Russia
Wildwest 07 Oct 2004, 21:30
You can rewrite set_bank in VESA12.INC:

set_bank:
cli
cmp al,[0xfff2]
je retsb
mov [0xfff2],al
push ax
push cx
push dx
mov dx,3D4h
mov ch,al ; Save value for later
and al,0Fh ; Mask off all but bottom 4 bits
mov cl,al
mov ax,4838h ; Enable extended registers
out dx,ax
mov al,31h ; Index of S3R1
out dx,al
inc dl
in al,dx ; Read value of S3R1
or al,9 ; Set bits 0 and 3
out dx,al ; Write value back again
dec dl
mov al,35h ; Index of S3R5
out dx,al
inc dl
in al,dx ; Read value of CR51
and al,0xC0
or al,cl
and ch,0xF0 ; [S3_mask] ; Mask out appropriate bits
shr ch,2
or al,ch ; Or in top 2 bits of bank number
out dx,al ; Write the value back again
dec dl
mov ax,0039h ; Lock system control registers
out dx,ax
@@S32: mov ax,0038h ; Disable extended registers
out dx,ax
pop dx
pop cx
pop ax
retsb:
ret

This code is not mine. I take it from menuetos.org.ru some months ago. Good luck!
Post 07 Oct 2004, 21:30
View user's profile Send private message Reply with quote
compilax



Joined: 18 Feb 2004
Posts: 56
compilax 22 Oct 2004, 05:47
In 0.78pre3, VESA12 is just a few comments describing code that is no longer present. Can I in some way replace VESA20.INC by an old VESA12.INC (and replace labels with their 2.0 counterparts) then apply that patch? Has 1.2 support been moved to another source file or completely abandoned? Why does it still show VESA 1.2 modes on boot?
Post 22 Oct 2004, 05:47
View user's profile Send private message Visit poster's website MSN Messenger Reply with quote
Tolle



Joined: 21 Jan 2004
Posts: 71
Tolle 22 Oct 2004, 14:06
Compilax, are you sure you are talking about the official 0.78pre3 menuetos.org distribution?

Now, who needs a new pair of glasses?
Post 22 Oct 2004, 14:06
View user's profile Send private message Visit poster's website Reply with quote
Madis731



Joined: 25 Sep 2003
Posts: 2139
Location: Estonia
Madis731 22 Oct 2004, 20:18
Yep, the VESA12.INC is absolutely clean of any code. They are
offering you a chance to write your own driver there Very Happy
Post 22 Oct 2004, 20:18
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger Reply with quote
ASHLEY4



Joined: 28 Apr 2004
Posts: 376
Location: UK
ASHLEY4 26 Oct 2004, 15:28
I read some thing in allegro, that there is a bug seting up vesa on S3 trio.
To get round it you setup vga mode 13h and then set vesa up and it works normal.
Not tryed it my self.

\\\\||////
(@@)
ASHLEY4.
Post 26 Oct 2004, 15:28
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.