]> git.sur5r.net Git - cc65/commitdiff
Now mkdir is working
authorjede <jede@oric.org>
Fri, 27 Oct 2017 22:37:47 +0000 (00:37 +0200)
committerjede <jede@oric.org>
Fri, 27 Oct 2017 22:37:47 +0000 (00:37 +0200)
asminc/telestrat.inc
libsrc/telestrat/oserror.s [new file with mode: 0644]
libsrc/telestrat/sysmkdir.s [new file with mode: 0644]

index 737c4b6aeedba94e42b8bf793242fbe9078fe06b..cb28919c26eb71c0c6bb5a16f1018ef47004359e 100644 (file)
@@ -171,6 +171,7 @@ XSOUND           = $44
 XMUSIC           = $45 
 XZAP             = $46
 XSHOOT           = $47
+XMKDIR           = $4B          ; create a folder. Only available in telemon 3.x
 XSOUT            = $67          ; send A register to RS232, available in telemon 2.4 & 3.x
 XHRSSE           = $8C          ; set hires position cursor
 XDRAWA           = $8D          ; draw a line 
diff --git a/libsrc/telestrat/oserror.s b/libsrc/telestrat/oserror.s
new file mode 100644 (file)
index 0000000..e3b9e61
--- /dev/null
@@ -0,0 +1,17 @@
+;
+; Jede, 2017-10-27
+;
+; int __fastcall__ _osmaperrno (unsigned char oserror);
+; /* Map a system specific error into a system independent code */
+;
+
+        .include        "errno.inc"
+        .export         __osmaperrno
+
+.proc   __osmaperrno
+
+        lda     #<EUNKNOWN
+        ldx     #>EUNKNOWN
+        rts
+
+.endproc
diff --git a/libsrc/telestrat/sysmkdir.s b/libsrc/telestrat/sysmkdir.s
new file mode 100644 (file)
index 0000000..26d97c4
--- /dev/null
@@ -0,0 +1,30 @@
+;
+; Jede (jede@oric.org), 2017-10-27
+;
+; unsigned char _sysmkdir (const char* name, ...);
+;
+
+        .export         __sysmkdir
+        .import         addysp, popax
+
+        .include        "telestrat.inc"
+        .include        "zeropage.inc"
+        
+
+__sysmkdir:
+        ; Throw away all parameters except the name
+        dey
+        dey
+        jsr     addysp
+
+        ; Get name
+        jsr     popax
+        
+        ; Call telemon primitive
+        
+        BRK_TELEMON(XMKDIR)
+        
+        rts
+
+
+