jankos/tests.c
2019-12-01 02:31:37 -08:00

28 lines
570 B
C

// Module for testing drivers and other things
#include "stlio.h"
#include "tests.h"
#include "serial.h"
void test_serial_write() {
char* serial1 = "0123456789abcdef0123456789abcdef";
serial_write(serial1, strlen(serial1));
printf("serial test write finished\n");
}
void test_write(void) {
char* msg1 = "Writing to fbout\n";
printf(msg1);
}
void test_dispatcher(void) {
clear_fb();
test_write();
test_write();
}
void test_read(void) {
char buf[5];
u32 bread = read(buf, 5);
printf("Bytes read: "); printhex(bread);
printf("String read: "); printf(buf);
}