Espresso 0.0.1f
This commit is contained in:
@ -3,10 +3,13 @@
|
||||
|
||||
#include <types.h>
|
||||
|
||||
int32_t sfs_init(bool format);
|
||||
int32_t sfs_init(void);
|
||||
|
||||
bool sfs_get_formatted_name(const char* raw_name, char output[37]);
|
||||
|
||||
int32_t sfs_read_file(char* name, void* buffer, uint32_t num);
|
||||
int32_t sfs_create_file(const char* _name, int32_t size_bytes);
|
||||
|
||||
int32_t sfs_read_file(char* name, void* buffer, int32_t num);
|
||||
int32_t sfs_write_file(char* _name, const void* buffer, int32_t num);
|
||||
|
||||
#endif
|
||||
|
||||
@ -13,6 +13,13 @@ extern "C" {
|
||||
//#define ENABLE_USB
|
||||
//#define ENABLE_NETWORK
|
||||
|
||||
typedef struct {
|
||||
bool enable_debug;
|
||||
bool enable_fs;
|
||||
bool enable_ide;
|
||||
bool enable_usb;
|
||||
bool enable_networking;
|
||||
} kconf_t;
|
||||
|
||||
static inline kconf_t get_kconfig(void)
|
||||
{
|
||||
|
||||
6
include/kincl.h
Normal file
6
include/kincl.h
Normal file
@ -0,0 +1,6 @@
|
||||
#ifndef _KERNEL_INCLUDES_H
|
||||
#define _KERNEL_INCLUDES_H
|
||||
|
||||
#define KERNEL_VERSION "0.0.1e"
|
||||
|
||||
#endif
|
||||
@ -1,30 +0,0 @@
|
||||
#ifndef _KERNEL_PANIC_H
|
||||
#define _KERNEL_PANIC_H
|
||||
|
||||
#include <stddef.h>
|
||||
#include <tty.h>
|
||||
|
||||
void panic(const char* arr)
|
||||
{
|
||||
|
||||
uint8_t color = 0x1F;
|
||||
uint8_t blank = 0xFF;
|
||||
|
||||
for (size_t y = 0; y < VGA_HEIGHT; y++)
|
||||
{
|
||||
for (size_t x = 0; x < VGA_WIDTH; x++)
|
||||
{
|
||||
const size_t index = y * VGA_WIDTH + x;
|
||||
VGA_MEMORY[index] = (uint16_t) ' ' | (uint16_t) blank << 8;
|
||||
}
|
||||
}
|
||||
|
||||
int i;
|
||||
for (i = 0; i < 75; i += 2)
|
||||
{
|
||||
VGA_MEMORY[i] = arr[i];
|
||||
VGA_MEMORY[i + 1] = color;
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
@ -1,6 +0,0 @@
|
||||
#ifndef _SYSCALL_H
|
||||
#define _SYSCALL_H
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user