Listing 1 /* plot() = plots a point on the screen at designated system coordinates using selected color. */ void plot(int x, int y, int color) { #define seq_out(index,val) {outp(0x3C4,index);\ outp(0x3C5,val);} #define graph_out(index,val) {outp(0x3CE,index);\ outp(0x3CF,val);} unsigned int offset; int dummy,mask,page; char far * mem_address; offset = (long)y * 80L + ((long)x / 8L); mem_address = (char far *) 0xA0000000L + offset; mask = 0x80 >> (x % 8); graph_out(8,mask); seq_out(2,0x0F); dummy = *mem_address; *mem_address = 0; seq_out(2,color); *mem_address = 0xFF; seq_out(2,0x0F); graph_out(3,0); graph_out(8,0xFF); }