Kernel version 0.9 : CP,RM,MV, Code rewrite in progress....#2

This commit is contained in:
Rémy GIBERT 2017-06-28 17:34:36 +02:00
parent ece6e1f056
commit 188e0c6393
4 changed files with 29 additions and 12 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -199,30 +199,43 @@ CS.RUN >SYSCALL GetC
bpl .1
.8 clc
rts
*--------------------------------------
.1 .DO X.COPY.TO.DEST=1
ldy #bCopy
lda (pData),y
bne .2
beq .2
jsr CS.RUN.Copy
ldy #bCopy Copy completed ?
lda (pData),y
bne .8
bne .8 no.....exit
ldy #bCopy
clc
ldy #CopyRC
lda (pData),y
beq .2 non copy error
.DO X.DELETE.SOURCE=0
beq .20 no copy error
sec
jsr CS.RUN.CheckErr we have an error....
bcs .9
jmp CS.RUN.NEXT
.DO X.DELETE.SOURCE=1
ldy #hToDelete
.20 jsr CS.RUN.CheckErr Success!!
jsr CS.RUN.IncCount
jmp CS.RUN.NEXT
.ELSE
beq .2
sec
jsr CS.RUN.CheckErr we have an error....
bcc .21
rts
.21 ldy #hToDelete
lda #0
sta (pData),y Cancel delete if any
jmp CS.RUN.NEXT
.FIN
.FIN
@ -231,19 +244,23 @@ CS.RUN >SYSCALL GetC
lda (pData),y
beq .3
pha
lda #0
sta (pData),y
pla
ldy #hSrcFullPath
lda (pData),y
>SYSCALL GetMemPtrA
>SYSCALL RemoveYA
.20 jsr CS.RUN.CheckErr
>SYSCALL RemoveYA
bcs .22
jsr CS.RUN.IncCount
jmp CS.RUN.NEXT
.22 jsr CS.RUN.CheckErr
bcs .9
jmp CS.RUN.NEXT
.FIN
*---------------
*--------------------------------------
.3 jsr GetEntry
bcs CS.RUN.LEAVE