rename hello to init

This commit is contained in:
2024-03-24 10:25:04 +01:00
parent aadc8148c1
commit fb2c56594f
3 changed files with 7 additions and 7 deletions

34
src/test/init.c Normal file
View File

@@ -0,0 +1,34 @@
#include "syscalls_interface.h"
__attribute__((unused)) void _start() {
// putchar('h');
// putchar('i');
// putchar('\n');
uint64_t test123 = open("/test123", O_CREAT | O_RDWR);
const char *teststr = "test str";
write(test123, teststr, 9);
close(test123);
test123 = open("/test123", O_RDONLY);
char buf[123];
read(test123, buf, 9);
putchar('\n');
for (int i = 0; i < 8; i++) {
putchar(buf[i]);
}
putchar('\n');
while (1) {
// putchar('h');
// putchar('i');
putchar('\n');
char read = readchar();
if (read == 'm') print_mem();
if (read == 't') print_tasks();
putchar('\n');
putchar(read);
// sleep(100000);
}
}