aboutsummaryrefslogtreecommitdiffstats
path: root/c/libc.s
diff options
context:
space:
mode:
Diffstat (limited to 'c/libc.s')
-rw-r--r--c/libc.s25
1 files changed, 25 insertions, 0 deletions
diff --git a/c/libc.s b/c/libc.s
index c245bbd..d499521 100644
--- a/c/libc.s
+++ b/c/libc.s
@@ -221,3 +221,28 @@ _bpeek2:
rst #0x30
ret
+
+ .globl _mkdir, _chdir
+ ;; unsigned char mkdir(const char *path /*DE*/) -> A (0 ok / $FF)
+_mkdir:
+ ld c, #25 ; SYS_MKDIR
+ rst #0x30
+ ret
+ ;; unsigned char chdir(const char *path /*DE*/) -> A (0 ok / $FF)
+_chdir:
+ ld c, #26 ; SYS_CHDIR
+ rst #0x30
+ ret
+
+ .globl _opendir
+ ;; unsigned char opendir(const char *path /*DE*/) -> A (0 ok / $FF)
+_opendir:
+ ld c, #27 ; SYS_OPENDIR
+ rst #0x30
+ ret
+
+ .globl _poweroff
+ ;; void poweroff(void) - execute the emulator's clean-exit opcode ($ED)
+_poweroff:
+ .db 0xED
+1$: jr 1$