Disk I/O in Pmode / VBE
Disk I/O in Pmode / VBE
I have entered pmode and are running C-code, how do i do disk I/O now? I can't use INT 13h now right?
Does anyone know where i can find docs on disk I/O?
Docs for VBE would be nice too..
Does anyone know where i can find docs on disk I/O?
Docs for VBE would be nice too..
Re:Disk I/O in Pmode / VBE
You don't have any functions for disk IO at your disposal. You cannot use the VBE functions if you didn't get a PM entry point, and there are lots that don't HAVE a pm entry point.Mullins wrote: I have entered pmode and are running C-code, how do i do disk I/O now? I can't use INT 13h now right?
Does anyone know where i can find docs on disk I/O?
Docs for VBE would be nice too..
Write your own drivers for them. (yes, that means, get the standards & write every sector writing operation yourself)
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:Disk I/O in Pmode / VBE
iirc, the docs for VBE are available on VBE.org ...
You can find an essay on writing disk drivers in pmode on my website
There are also basic documentations about HDD programming on OSRC (see .:QuickLinkz:.)
However, in a first time, it could be more interresting for you to load as much as you need while you're still in (un)real mode and have your pmode code working on a ramdisk rather than on real hardware ...
Same goes for the VBE stuff ... stick with text mode as long as graphics aren't really necessary and if you want to enable graphic mode before you have the required things in your OS (pmode entry point lookup or Vm86 support), just set up the required mode in your realmode bootloader ...
You can find an essay on writing disk drivers in pmode on my website
There are also basic documentations about HDD programming on OSRC (see .:QuickLinkz:.)
However, in a first time, it could be more interresting for you to load as much as you need while you're still in (un)real mode and have your pmode code working on a ramdisk rather than on real hardware ...
Same goes for the VBE stuff ... stick with text mode as long as graphics aren't really necessary and if you want to enable graphic mode before you have the required things in your OS (pmode entry point lookup or Vm86 support), just set up the required mode in your realmode bootloader ...
Re:Disk I/O in Pmode / VBE
Thanks, that should be enough to get me started
Btw, VBE is just for fun.
Btw, VBE is just for fun.
Re:Disk I/O in Pmode / VBE
Try this link:
http://debs.future.easyspace.com/Progra ... loppy.html
As for vesa you have to initialize it in real mode,or use v86.
ASHLEY4.
http://debs.future.easyspace.com/Progra ... loppy.html
As for vesa you have to initialize it in real mode,or use v86.
ASHLEY4.
Re:Disk I/O in Pmode / VBE
Why? If you know how, you should be able to set it in pmode, or?As for vesa you have to initialize it in real mode,or use v86.
/ Christoffer
Re:Disk I/O in Pmode / VBE
if you know how you don't use vesa. VESA is the name for the 16-bit BIOS extensions (and nowadays the 32-bit extensions, that are barely present in practice). If you can use some method that works, you're not using vesa but you've written a normal driver.bubach wrote:Why? If you know how, you should be able to set it in pmode, or?As for vesa you have to initialize it in real mode,or use v86.
/ Christoffer
As for that, if I make a v86 monitor, that logs every bit & byte the realmode prog out() & in()s do I get the info for a driver? If so, that'd rock.
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:Disk I/O in Pmode / VBE
well, you'll not exactly have a driver ... what you'll have is a communication for *one* instanciation. As there are usually timings and status polling in such a communication, i'm unsure it will be replayable, and i doubt it will be usable on another graphic card that yours...
btw, most PCI configuration goes through memory-mapped registers, so in/outs will no longer be of any help
btw, most PCI configuration goes through memory-mapped registers, so in/outs will no longer be of any help
Re:Disk I/O in Pmode / VBE
it's in the v86 monitor, doubt there's a lot of timing issues.Pype.Clicker wrote: well, you'll not exactly have a driver ... what you'll have is a communication for *one* instanciation. As there are usually timings and status polling in such a communication, i'm unsure it will be replayable, and i doubt it will be usable on another graphic card that yours...
Memory mapped IO could still be done, just manually progress the cursor, or disassemble the video bios (yes I'm a sick dude).
Re:Disk I/O in Pmode / VBE
forget my stupid comment above. i know that! *blames it on that i have been so tired latly*
Why not disassemble a bios and check it out? Where lies the vesa info? becasue i think i have a disassembled BIOS on my hd at home..
Then we could (together?) make a great video driver..
/ Christoffer
Why not disassemble a bios and check it out? Where lies the vesa info? becasue i think i have a disassembled BIOS on my hd at home..
Then we could (together?) make a great video driver..
/ Christoffer
Re:Disk I/O in Pmode / VBE
vesa is the interface between your prog and the driver for the video card. If you disassemble the bios you get a driver for only that video card, possibly only that series. Other ways might be betterbubach wrote: forget my stupid comment above. i know that! *blames it on that i have been so tired latly*
Why not disassemble a bios and check it out? Where lies the vesa info? becasue i think i have a disassembled BIOS on my hd at home..
Then we could (together?) make a great video driver..
/ Christoffer
Re:Disk I/O in Pmode / VBE
but if i am i real mode in my os and i set some svga mode with vesa. where is the driver? not in my os anyway.. so the drivers should be somewhere in the bios (for all cards), right?
/ Christoffer
/ Christoffer
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:Disk I/O in Pmode / VBE
btw, informations about how to set up video modes are usually available for most cards (Xfree86 is the best example of it ... VESA is simply a "least resistance" way that ensures you that you'll be able to turn on *any* card and not just "the card you have at home" ...
Re:Disk I/O in Pmode / VBE
No. The driver is in the video bios that is on your video card. There's no reason why it should have all video card drivers there, so they aren't there.bubach wrote: but if i am i real mode in my os and i set some svga mode with vesa. where is the driver? not in my os anyway.. so the drivers should be somewhere in the bios (for all cards), right?
/ Christoffer
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:Disk I/O in Pmode / VBE
Indeed. Everything under 0xC000:xxxx is the memory-mapped video ROM directly from your video card. It exists from the old ages of PC XT iirc. That's a pitty network card have no such things ...Candy wrote:
No. The driver is in the video bios that is on your video card. There's no reason why it should have all video card drivers there, so they aren't there.