Page 1 of 1
vesa text modes
Posted: Fri Oct 30, 2009 4:29 pm
by ehenkes
If I switch during bootloading by
Code: Select all
mov ax, 0x4F02
mov bx, 0x010C ; text mode 132*60
int 0x10
into a text mode, how can I use it later in the kernel using PM?
Is there a video RAM like b8000h?
Re: vesa text modes
Posted: Fri Oct 30, 2009 5:09 pm
by Combuster
I'd have read the official (VESA VBE) specification before I would (not) have posted that question
Also, necro alert.
Re: vesa text modes
Posted: Fri Oct 30, 2009 10:24 pm
by neon
This was posted a year ago...
Assuming that the video mode was set to support LFB, you can grab a pointer to its frame buffer (see the specs to find out how.) If not, its probably at 0xa0000 but you will need to provide a way to support switching between banks.
I personally have been using VGA in protected mode as my system is not up to par yet to support VBE to my standards. (I have high standards in design...)
Re: vesa text modes
Posted: Sat Oct 31, 2009 4:52 am
by AJ
Hi,
I have now split the topic, hence Neon and Combuster's reference to thread necromancy!
Cheers,
Adam
Re: vesa text modes
Posted: Sat Oct 31, 2009 8:58 am
by Tobiking
I tried it yesterday before ehenkes wrote this. The graphic modes (with lfb) work without problems, but the text modes don't (tested in qemu and bochs). I think ehenkes tried it on real hardware, too. Maybe there is a lack of support for the text modes?
The idea was to find an easy way to extend the normal 80x25 display to be able to put more information on the screen. Using the graphic mode and drawing own fonts seems a bit to much work right now.
Re: vesa text modes
Posted: Sat Oct 31, 2009 11:18 am
by Dex
You can always use 80x50 as easy as 80x25
Re: vesa text modes
Posted: Mon Nov 02, 2009 4:01 am
by jal
ehenkes wrote:into a text mode, how can I use it later in the kernel using PM?
Is there a video RAM like b8000h?
If I'm not mistaken, the VESA video mode information structure contains a field indicating the base address for the video mode. Unfortunately, VGABIOS (and thus Bochs) does not support VESA text modes. On a standard VGA, the highest text resolution you can get is 90x60 (720x480 pixels, 8x8 characters).
JAL
Re: vesa text modes
Posted: Tue Nov 03, 2009 7:42 pm
by smeezekitty
i fail to see where 80x25, 80x50 and even 90x60 is not enough for text mode?
Re: vesa text modes
Posted: Tue Nov 03, 2009 8:04 pm
by Tobiking
smeezekitty wrote:i fail to see where 80x25, 80x50 and even 90x60 is not enough for text mode?
80x50 is sufficent and it's used for now, but 80x25 wasn't. Printing information about found pci devices takes some space and there is no way to scroll up in the kernel right now.
Re: vesa text modes
Posted: Mon Nov 09, 2009 1:45 am
by ehenkes
You can always use 80x50 as easy as 80x25
Yes, as Tobiking already mentioned, we have found this possibility and use this 80*50 with 8*8 fonts (a little bit ugly, but helpful) for the time being.
Code: Select all
;;;;; set 80x50 text mode and 8x8 font
mov ax, 0x1112
xor bl, bl
int 0x10
;;;;;
Could we also expand that resolution to 90*60 in this easy way?
Re: vesa text modes
Posted: Mon Nov 09, 2009 4:09 am
by jal
ehenkes wrote:Could we also expand that resolution to 90*60 in this easy way?
No, unfortunately not. 90x60 needs reprogramming the VGA controller. It's not
that difficult (search the forum, it has come up a few times, with source code), but not as easy as a simple int 10h call.
JAL