aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/io.c
blob: b6ea80c7ae4c52dd6f314d938c8cf165231f5ec6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include "api/io.h"

/*
 *    Minimal API for kernel I/O basics
 */

volatile uint16_t* VGA = (volatile uint16_t*)0xB8000;
uint16_t cursor = 0;

void VGA_RPrint(const char* str)
{
    while(*str) {
                                          // white on black
        VGA[cursor++] = (uint8_t)(*str) | 0x0700;
        str++;
    }
}