1 /*
2  * Copyright (c) 2006-2008 Ali Mashtizadeh
3  */
4 
5 #ifndef __VGA_H__
6 #define __VGA_H__
7 
8 /*
9  * Using 4 80x60 screens with an 8x8 font
10  */
11 #define SCREEN_CONSOLE  1
12 #define SCREEN_KLOG     2
13 #define SCREEN_KDEBUG   3
14 #define SCREEN_EXTRA    4
15 #define MAX_SCREENS     4
16 
17 #define COLOR_BLACK         0
18 #define COLOR_BLUE          1
19 #define COLOR_DARKGRAY      2
20 #define COLOR_LIGHTBLUE     3
21 #define COLOR_RED           4
22 #define COLOR_MAGENTA       5
23 #define COLOR_LIGHTRED      6
24 #define COLOR_LIGHTMAGENTA  7
25 #define COLOR_GREEN         8
26 #define COLOR_CYAN          9
27 #define COLOR_LIGHTGREEN    10
28 #define COLOR_LIGHTCYAN     11
29 #define COLOR_BROWN         12
30 #define COLOR_LIGHTGREY     13
31 #define COLOR_YELLOW        14
32 #define COLOR_WHITE         15
33 
34 void VGA_Init(void);
35 void VGA_LateInit(void);
36 void VGA_SwitchTo(int screen);
37 void VGA_LoadFont(void *fontBuffer, int maxLength);
38 void VGA_SaveFont(void *fontBuffer, int maxLength);
39 void VGA_ClearDisplay(void);
40 void VGA_ScollDisplay(void);
41 void VGA_Putc(short ch);
42 void VGA_Puts(const char *str);
43 void Panic(const char *str);
44 
45 #endif /* __VGA_H__ */
46 
47