Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!uunet!inpnms!logan From: logan@inpnms.UUCP (Jim Logan) Newsgroups: comp.unix.i386 Subject: Re: X problem with 386ix 2.0.2 and mono VGA screen Message-ID: <233@inpnms.UUCP> Date: 1 Mar 90 22:13:10 GMT References: <1990Feb19.195600.7778@hcr.uucp> <232@inpnms.UUCP> Reply-To: logan@inpnms.UUCP (Jim Logan) Organization: Data General Telecommunications, Rockville, MD Lines: 98 In article <232@inpnms.UUCP> logan@inpnms.UUCP I wrote: # In article <1990Feb19.195600.7778@hcr.uucp> jeff@hcr.uucp (Jeffrey Roberts) # writes: # # When 'X' is started up from any virtual terminal, ie: console, vt01 etc.. # # 'X' starts up with no problem. If I switch to another virtual terminal # # I can see the cursor but nothing else, ie: any characters that I type # # are invisible. # # This only happens when a mono VGA monitor is used. # # Not true. This also happens to me when I use X with an EGA # board. I intend to look through the documentation to see if # there is an ioctl() call that can be used to re-initialize the # screen(s). I'll let you in on it if I find anything. Here is a temporary solution to the problem, and a way to access the EGA 43-line mode. It's just a quick hack, but it works. ------------------8<-------------------------------------------------------- /* * mode.c James Logan Tue Feb 27 19:13:07 EST 1990 * Change video modes on the current virtual terminal. */ #include #include #include #include #include #define MAXMODES 19 extern void exit(), perror(); char *MyName; int ModeNum, Modes[MAXMODES] = { SW_B40x25, SW_C40x25, SW_B80x25, SW_C80x25, SW_BG320, SW_CG320, SW_BG640, SW_CG320_D, SW_CG640_E, SW_EGAMONOAPA, SW_CG640x350, SW_ENH_CG640, SW_EGAMONO80x25, SW_ENHB40x25, SW_ENHC40x25, SW_ENHB80x25, SW_ENHC80x25, SW_ENHB80x43, SW_ENHC80x43 }; int main(argc, argv) int argc; char **argv; { MyName = *argv; if (argc != 2) { (void) fprintf(stderr, "Usage: %s mode-number\n", MyName); exit(2); /*NOTREACHED*/ } ModeNum = atoi(argv[1]); if (ModeNum < 0 || ModeNum > MAXMODES) { (void) fprintf(stderr, "%s: mode-number must be between 0 and %d.\n", MyName); exit(1); /*NOTREACHED*/ } if (ioctl(0, Modes[ModeNum], 0) == -1) { perror("ioctl"); exit(1); /*NOTREACHED*/ } exit(0); /*NOTREACHED*/ } ------------------8<-------------------------------------------------------- -- James Logan UUCP: uunet!inpnms!logan Data General Telecommunications Inet: logan%inpnms@uunet.uu.net (301) 590-3198