I have some code that sets up a 640x480x8 VESA mode (in my boot-sector).
...
So this is what I want to do! After searching I can't find anything helpful on this, though...
How do I do this?
Thanks,
Lster
Vesa In PMode
Vesa In PMode
Last edited by Lprogster on Sun Jul 22, 2007 12:40 pm, edited 2 times in total.
I haven't written any VESA code, but according to http://www.osdev.org/wiki/Getting_VBE_Mode_Info, the screen buffer (framebuffer) address is stored in the mode info block. Look at http://www.ctyme.com/intr/rb-0274.htm; the framebuffer address is 40 bytes into that table. You should be able to call that from your bootloader and pass the information to your kernel.
-
- Member
- Posts: 2566
- Joined: Sun Jan 14, 2007 9:15 pm
- Libera.chat IRC: miselin
- Location: Sydney, Australia (I come from a land down under!)
- Contact:
My mode switcher is run once full initialization is complete (it's loaded off the drive as a virtual mode task).
It basically finds the mode you want to enter, then finds out if that mode supports a LFB, if so, switches to that mode and returns the address of the LFB.
Edit: come to think of it, I don't see the relevance of what I just said, unless you need some NASM code that shows how to safely switch modes (and gracefully die if it can't) in which case I should just say, PM me.
It basically finds the mode you want to enter, then finds out if that mode supports a LFB, if so, switches to that mode and returns the address of the LFB.
Edit: come to think of it, I don't see the relevance of what I just said, unless you need some NASM code that shows how to safely switch modes (and gracefully die if it can't) in which case I should just say, PM me.