changelog shortlog tags branches changeset files revisions annotate raw help

Mercurial > hg > plan9front / sys/src/games/blit/dat.h

changeset 6228: f4fa0b9d0397
parent: 84a6cae21f1f
child: 211ff2caec74
author: cinap_lenrek@felloff.net
date: Sun, 26 Nov 2017 17:11:01 +0100
permissions: -rw-r--r--
description: cga: capture cga console contents on boot, make sure cgapos is in range

to capture bios and bootloader messages, convert the contents
on the screen to kmesg.

on machines without legacy cga, the cga registers read out as
0xFF, resuting in out of bounds cgapos. so set cgapos to 0 in
that case.
1 typedef signed char s8int;
2 typedef signed short s16int;
3 typedef signed long s32int;
4 
5 extern u32int curpc, irq;
6 extern int trace, debug;
7 
8 extern ushort ram[128*1024];
9 
10 extern int daddr;
11 extern ushort dstat;
12 extern uchar invert;
13 
14 extern int mousex, mousey, mousebut;
15 
16 extern int vblctr, uartrxctr;
17 extern int baud;
18 
19 enum {
20  INTKEY = 1,
21  INTMOUSE = 2,
22  INTUART = 4,
23  INTVBL = 8,
24 };
25 
26 enum {
27  SX = 800,
28  SY = 1024,
29  FREQ = 8000*1000,
30  VBLDIV = FREQ / 60,
31 };