flat assembler
Message board for the users of flat assembler.

Index > OS Construction > SVGA/VESA in protected mode - Possible?

Author
Thread Post new topic Reply to topic
smoke



Joined: 16 Jan 2006
Posts: 42
smoke 06 May 2007, 16:52
Hello,

I was wondering if anyone can give me any useful information on how to use SVGA mode in protected mode ... I've read some articles on google and found out that BIOS Interrupts cant be called from protected mode...
What can I do about it ?

regards
Post 06 May 2007, 16:52
View user's profile Send private message Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Dex4u 06 May 2007, 18:18
Hi,
There is about 3 ways to use vesa form pmode, 1. use vesa3 from pmode, but i have not to date found anyone who has got it working. 2. you can code a v86 see here: http://www.computerhope.com/jargon/v/virtreal.htm
or 3. do what i do and go back to realmode, switch vesa modes and return to PM, (as you can use the LFB from pmode). Here is a veas demo i made to show how it is done.
http://www.dex4u.com/demos/VesaDemo.zip

This demo switch's between vesa 640x480 32bpp and text mode, it delays about 10 second between the two, then goes to real mode switch's and returns to pmode for 10 seconds. It comes with fasm source code and a exe to make a floppy bootable, with the demo on.
So to run it you will need a vesa2 capable PC and floppy drive.

NOTE: I was called ASHLEY4, when i wrote it.


Last edited by Dex4u on 23 Feb 2008, 14:19; edited 1 time in total
Post 06 May 2007, 18:18
View user's profile Send private message Reply with quote
smoke



Joined: 16 Jan 2006
Posts: 42
smoke 07 May 2007, 12:29
Hello,

Thanks for the reply! I think i'll go for the third option then Smile.
Im just curious if i can run such a program on windows without crashing? for example if i code a driver that will run in ring0 and wait till I press certain key this driver writes my program on the screen?
Post 07 May 2007, 12:29
View user's profile Send private message Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1905
DOS386 08 May 2007, 10:41
Quote:
I think i'll go for the third option then


Seems also good to me. See also my "VESA from DPMI" thread in DOS. Smile

Quote:
just curious if i can run such a program on windows without crashing


Yeah ... people really should get rid of the assumption that everything must and will run in "Windows". Sad You can't run DOS code in Windows Shocked (except some bad "NTVDM" emulation maybe), and even less no-OS code with raw mode switches. Laughing

- Terminate your "Windows" (possible at all) ? Laughing
or
- Use BOCHS or QEMU

No-OS code can be tested in DOS with some care ... and limitations. Idea

Quote:
if i code a driver that will run in ring0 and wait till I press certain key this driver writes my program on the screen


OK, you can do 1000 times more complicated Laughing - maybe this would even work Shocked

_________________
Bug Nr.: 12345

Title: Hello World program compiles to 100 KB !!!

Status: Closed: NOT a Bug
Post 08 May 2007, 10:41
View user's profile Send private message Reply with quote
smoke



Joined: 16 Jan 2006
Posts: 42
smoke 08 May 2007, 12:34
NTOSKRNL_VXE: hm i think you understood me wrong... i dont want an OS to emulate my code (for example windows) i was wondering if i can write on my screen while some os is running (windows or not windows) Smile so i either need to switch to realmode (but i have no idea what would that do other programs running at the same time) or find a way to call interrupts from protected mode.
Post 08 May 2007, 12:34
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 cannot attach files in this forum
You can download files in this forum


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

Website powered by rwasa.