Kernel 0.93+

This commit is contained in:
Rémy GIBERT 2019-10-29 21:48:34 +01:00
parent 39d4efd96e
commit a91acdf380
2 changed files with 42 additions and 25 deletions

Binary file not shown.

View File

@ -22,21 +22,32 @@ CMD.NOHUP lda #S.PS.F.NOHUP
>LDYA ZPArgVBuf
jmp CORE.ExecExtCmd
*--------------------------------------
CMD.SHIFT lda #1
CMD.SHIFT lda (ZPArgVBufPtr)
beq CMD.SHIFT.1
jsr CMD.GetInt8Arg
bcs CMD.SHIFTA.RTS
.HS B0 BCS
CMD.SHIFT.1 inc
CMD.SHIFTA >SYSCALL ArgV
bcs .8
jsr RemoveStrFromArgV
.7 ldy #S.PS.ARGC
ldy #S.PS.ARGC
lda (pPS),y
dec
sta (pPS),y
.8 clc
CMD.SHIFTA.RTS rts
*--------------------------------------
CMD.PUSHD >LDA.G PUSHD.STACK
cmp #PUSHD.STACK+PUSHD.STACK.MAX
beq CMD.POPD.CSYN
ldy #S.PS.hCWD
lda (pPs),y
>SYSCALL GetMemPtr
@ -350,13 +361,17 @@ CMD.READ lda (ZPArgVBufPtr)
.1 jsr CMD.IsSwitch
bcs .4
cmp #'S'
bne .2
lda #$ff
>STA.G bREAD.S
bra .5
.2 cmp #'P'
bne .3
jsr CORE.ArgV.Next
beq .9
@ -369,26 +384,25 @@ CMD.READ lda (ZPArgVBufPtr)
.9 jmp CMD.E.CSYN
.3 cmp #'N'
bne .9
jsr CORE.ArgV.Next
beq .9
>LDYA ZPArgVBufPtr
>SYSCALL AToL
jsr CMD.GetInt8Arg
bcs CMD.ECHO.RTS
>PULLA
>STA.G READ.N
inc pStack
inc pStack
inc pStack
bra .5
.4 >LDYA ZPArgVBufPtr
>STYA ZPVarNamePtr
.5 jsr CORE.ArgV.Next
bne .1
lda ZPVarNamePtr+1
beq .9
CMD.READ.VAR jsr CL.Reset
.1 >SYSCALL GetChar
bcs CMD.READ.VAR.9
@ -640,19 +654,9 @@ CMD.CALL >LDA.G hFuncList
CMD.EXIT lda (ZPArgVBufPtr)
beq .1 no arg, exit 0
>LDYA ZPArgVBufPtr
jsr EXP.GET
jsr CMD.GetInt8Arg
bcs .9
>SYSCALL AToL
bcs .99
>PULLA
inc pStack
inc pStack
inc pStack
.1 sta M32.ACC
.2 jsr CORE.StkPull Pull everything until CALL . CL...
@ -668,10 +672,6 @@ CMD.EXIT lda (ZPArgVBufPtr)
bcc .2
.9 rts
.99 lda #E.ESYN
* sec
rts
*--------------------------------------
CMD.EXIT.SH jsr CMD.EXIT.FILE
@ -1223,6 +1223,23 @@ CMD.IsSwitch lda (ZPArgVBufPtr)
.9 sec
rts
*--------------------------------------
CMD.GetInt8Arg >LDYA ZPArgVBufPtr
jsr EXP.GET
bcs .9
>SYSCALL AToL
bcs .99
>PULLA
inc pStack
inc pStack
inc pStack
.99 lda #E.ESYN
* sec
.9 rts
*--------------------------------------
MAN
SAVE USR/SRC/BIN/SH.S.CMD
LOAD USR/SRC/BIN/SH.S