mirror of
https://github.com/SmallPond/MIT6.828_OS.git
synced 2026-04-28 21:01:11 +08:00
LAB 4 IS DONE.
This commit is contained in:
26
lab/kern/console.h
Normal file
26
lab/kern/console.h
Normal file
@@ -0,0 +1,26 @@
|
||||
/* See COPYRIGHT for copyright information. */
|
||||
|
||||
#ifndef _CONSOLE_H_
|
||||
#define _CONSOLE_H_
|
||||
#ifndef JOS_KERNEL
|
||||
# error "This is a JOS kernel header; user programs should not #include it"
|
||||
#endif
|
||||
|
||||
#include <inc/types.h>
|
||||
|
||||
#define MONO_BASE 0x3B4
|
||||
#define MONO_BUF 0xB0000
|
||||
#define CGA_BASE 0x3D4
|
||||
#define CGA_BUF 0xB8000
|
||||
|
||||
#define CRT_ROWS 25
|
||||
#define CRT_COLS 80
|
||||
#define CRT_SIZE (CRT_ROWS * CRT_COLS)
|
||||
|
||||
void cons_init(void);
|
||||
int cons_getc(void);
|
||||
|
||||
void kbd_intr(void); // irq 1
|
||||
void serial_intr(void); // irq 4
|
||||
|
||||
#endif /* _CONSOLE_H_ */
|
||||
Reference in New Issue
Block a user