Added runtime (kernel 2.0)

This commit is contained in:
felsabbagh3
2019-10-30 23:40:01 -04:00
parent 06e5f6df1d
commit 46b09028d0
37 changed files with 569 additions and 3866 deletions

30
runtime/io/vx_io.c Normal file
View File

@@ -0,0 +1,30 @@
#include "vx_io.h"
void vx_print_hex(unsigned f)
{
vx_print_str(hextoa[f]);
// if (f < 16)
// {
// vx_print_str(hextoa[f]);
// return;
// }
// int temp;
// int sf = 32;
// bool start = false;
// do
// {
// temp = (f >> (sf - 4)) & 0xf;
// if (temp != 0) start = true;
// if (start) vx_print_str(hextoa[temp]);
// sf -= 4;
// } while(sf > 0);
}
void vx_printf(char * c, unsigned f)
{
vx_print_str(c);
vx_print_hex(f);
vx_print_str("\n");
}