2 * Name: video_defines.h
3 * Date: January 15th 2003
4 * Author: Steve Muckle <smuckle@andrew.cmu.edu>
8 * Important values for console output.
11 #ifndef _VIDEO_DEFINES_H
12 #define _VIDEO_DEFINES_H
14 #define CONSOLE_MEM_BASE 0xB8000
15 #define CONSOLE_WIDTH 80
16 #define CONSOLE_HEIGHT 25
18 /* Bits 3:0 are the foreground color, bits 6:4 are the
19 background color, and bit 7 specifies blink (annoying). */
20 #define FGND_BLACK 0x0
22 #define FGND_GREEN 0x2
27 #define FGND_LGRAY 0x7 /* Light gray. */
28 #define FGND_DGRAY 0x8 /* Dark gray. */
29 #define FGND_BBLUE 0x9 /* Bright blue. */
30 #define FGND_BGRN 0xA /* Bright green. */
31 #define FGND_BCYAN 0xB /* Bright cyan. */
33 #define FGND_BMAG 0xD /* Bright magenta. */
35 #define FGND_WHITE 0xF
37 #define BGND_BLACK 0x00
38 #define BGND_BLUE 0x10
39 #define BGND_GREEN 0x20
40 #define BGND_CYAN 0x30
43 #define BGND_BRWN 0x60
44 #define BGND_LGRAY 0x70 /* Light gray. */
46 #define BLINK 0x80 /* Annoying. */
48 /* --- CRTC Register Manipulation --- */
50 #define CRTC_IDX_REG 0x3d4
51 #define CRTC_DATA_REG 0x3d5
53 #define CRTC_START_ADDR_MSB_IDX 0xC
54 #define CRTC_START_ADDR_LSB_IDX 0xD
55 #define CRTC_CURSOR_MSB_IDX 0xE
56 #define CRTC_CURSOR_LSB_IDX 0xF