23 lines
369 B
C
23 lines
369 B
C
|
|
#include "include/string.h"
|
||
|
|
|
||
|
|
#include "../syscall.h"
|
||
|
|
|
||
|
|
#include "include/stdio.h"
|
||
|
|
|
||
|
|
|
||
|
|
int writestring(const char* __s)
|
||
|
|
{
|
||
|
|
/*syscall1(SYS_TERMINAL_WRITESTRING, __s);*/
|
||
|
|
return syscall3(SYS_WRITE, 1, __s, strlen(__s));
|
||
|
|
}
|
||
|
|
|
||
|
|
void writechar(char __c)
|
||
|
|
{
|
||
|
|
syscall1(SYS_TERMINAL_PUTCHAR, __c);
|
||
|
|
}
|
||
|
|
|
||
|
|
int getstring(char* __str)
|
||
|
|
{
|
||
|
|
return syscall3(SYS_READ, 0, __str, 0);
|
||
|
|
}
|