mirror of
https://github.com/Tom-on64/kern.git
synced 2026-11-03 18:22:22 +00:00
Began work on tty driver
This commit is contained in:
+15
-2
@@ -18,7 +18,20 @@
|
||||
#define __naked __attribute__((naked))
|
||||
|
||||
/*
|
||||
* Utility macros
|
||||
* Standard int types
|
||||
*/
|
||||
#define sizeof_array(_a) ()
|
||||
// Unsigned
|
||||
typedef unsigned char uint8_t;
|
||||
typedef unsigned short uint16_t;
|
||||
typedef unsigned int uint32_t;
|
||||
typedef unsigned long uint64_t;
|
||||
// Signed
|
||||
typedef signed char int8_t;
|
||||
typedef signed short int16_t;
|
||||
typedef signed int int32_t;
|
||||
typedef signed long int64_t;
|
||||
// Size
|
||||
typedef uint32_t size_t;
|
||||
typedef int32_t ssize_t;
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
#ifndef _TTY_H
|
||||
#define _TTY_H
|
||||
|
||||
/* VGA Text mode */
|
||||
#define VGA_WIDTH 80
|
||||
#define VGA_HEIGHT 25
|
||||
#define VGA_MEMORY 0xb8000
|
||||
|
||||
int tty_init(void);
|
||||
int tty_write(char* buf, size_t len);
|
||||
int tty_putc(char c);
|
||||
|
||||
Reference in New Issue
Block a user