Mail Archives: djgpp/2004/09/26/04:19:17
I have a dual boot computer, I can either boot into Windows XP or DOS from
Windows 98 ( from http://newdos.yginfo.net/msdos71/index.htm).
Anyway, I'm messing around geting VBE info with function 0 and then printing it
out on the screen, and, under the DOS box from Windows XP, everything runs
fine, but try to run my program under pure DOS and none of the strings return
anything.
I called my VBE info block structure "vesainfo". For an exaple, using long
OEM_String_PTR I'll show how I get the string to print.
I have variables char OEM_String[255]; and short Real_Mode_PTR;
To get the OEM String pointer:
Real_Mode_PTR = ((vesainfo.OEM_String_PTR >> 16) << 4) +
(vesainfo.OEM_String_PTR & 0xFFFF);
dosmemget(Real_Mode_PTR & 0xFFFF, 255, &OEM_String);
Now, if I
printf("Chipset or OEM %s \n", &OEM_String);
under Windows XP DOS box, it prints out the string, but under pure DOS, it
doesn't. Does anybody have any ideas why? Thanks.
- Raw text -