news:BM2dneOJr6tkRoHM...@giganews.com...
> The main use I was going to use [RM] for was
> switching graphics modes via int10.
Well, I program the video controller from scratch for a single
text video mode. I used info from the Internet. The routine is
neither small nor simple. IIRC, there is lots of info on
programming for VGA modes too. I wouldn't bother with EGA or CGA.
(Is that consensus here?) SVGA modes may require calling the BIOS
... (custom registers ?)
Along the way, I also found Chris Giese's vm86.c to be interesting
(for DOS, in C, for DJGPP or OpenWatcom). It's a v86 monitor that
blocks I/O ports by default, when trapped unblocks and reissues
them. The code can be slightly modified and recompiled to emit
the ports called. So, you can "see" what ports that BIOS routine
calls. I.e., you can check that registers you programmed match
what the BIOS call is actually using, or that the sequence is
correct. That only works for the tested machine's BIOS, though.
I.e., one machine may use a few special registers while another
may not...
A novel use for v86 mode would be for someone to use it to build a
used port map of BIOS routines across multiple BIOSes. A while
back, I suggested a program to test a bunch of RM BIOS routines
and save the output for a setup file for the OS, e.g., results of
E820h memory, A20 methods, etc. That way the host OS wouldn't
need RM support. It could just read the saved results in that
file. A more in depth BIOS tester program could also save the
ports used for a variety of BIOS calls. The advantage to this is
someone could run the program in DOS and it would save the I/O
ports and values, e.g., for setting a specific SVGA mode, or for
disk I/O. E.g., this should allow the host OS to set any tested
video mode without needing a routine. Write the same values to
the same I/O ports.
I know James did some testing on the availability and
functionality of A20 routines in the BIOS. As a hobbyist OS
developer, it'd be really nice to have much more info than I do
have on the capabilities of various BIOS calls on various BIOSes.
Basically, all I have is RBIL and some very useless info I collect
on 32-bit PM BIOS...
Rod Pemberton