diff --git a/.Floppies/A2OSX.BUILD.po b/.Floppies/A2OSX.BUILD.po index 3366855c..111d1f9b 100644 Binary files a/.Floppies/A2OSX.BUILD.po and b/.Floppies/A2OSX.BUILD.po differ diff --git a/BIN/CAT.S.txt b/BIN/CAT.S.txt index 0f8b35bc..bd153a92 100644 --- a/BIN/CAT.S.txt +++ b/BIN/CAT.S.txt @@ -11,8 +11,14 @@ AUTO 4,1 .INB INC/MLI.I .INB INC/MLI.E.I *-------------------------------------- -ZPPTR1 .EQ ZPBIN -ZPBufPtr .EQ ZPBIN+2 + .DUMMY + .OR ZPBIN +ZS.START +ZPPTR1 .BS 2 +ZPBufPtr .BS 2 +BytesRead .BS 1 +ByteIndex .BS 1 +ZS.END .ED *-------------------------------------- * File Header (16 Bytes) *-------------------------------------- @@ -25,7 +31,7 @@ CS.START cld .DA CS.END-CS.START CS .DA DS.END-DS.START DS .DA #16 SS - .DA #4 ZP + .DA #ZS.END-ZS.START Zero Page Size .DA 0 *-------------------------------------- * Relocation Table @@ -35,7 +41,6 @@ CS.START cld .DA CS.DOEVENT .DA CS.QUIT L.MSG.USAGE .DA MSG.USAGE -L.MSG.Init .DA MSG.Init L.MSG.LINENUM .DA MSG.LINENUM L.MSG.CTRLCHAR .DA MSG.CTRLCHAR L.ASCII .DA ASCII @@ -89,12 +94,7 @@ CS.INIT >STYA ZPBufPtr txa >STA.G hBuf - - -* >PUSHBI 0 -* >LDYA L.MSG.Init -* >SYSCALL printf - + clc .9 rts *-------------------------------------- @@ -144,7 +144,7 @@ CS.RUN bra .11 >PUSHWI 256 >PUSHW ZPBufPtr pla - >SYSCALL FRead + >SYSCALL fread bcc CS.RUN.PRINT @@ -162,7 +162,7 @@ CS.RUN bra .11 *-------------------------------------- CS.RUN.PRINT sty BytesRead Y,A = Bytes read stz ByteIndex - + * jsr PrintStack >INCW.G LineNum @@ -223,14 +223,14 @@ CS.RUN.PRINT sty BytesRead Y,A = Bytes read .3 >PUSHW ZPPtr1 >PUSHBI 2 - >LDYA L.MSG.CTRLCHAR + >LDYA L.MSG.CTRLCHAR >SYSCALL printf bcs .9 bra .7 .4 lda #13 - >SYSCALL PutChar + >SYSCALL PutChar bcs .9 lda #10 @@ -256,32 +256,26 @@ CS.RUN.PRINTNUM clc >SYSCALL printf .8 rts *-------------------------------------- -CS.RUN.OPEN pha +CS.RUN.OPEN phy + pha + + lda #0 + >STA.G bPrintedBlankLine Reset this flag for the new file >PUSHWI 0 Aux type >PUSHBI S.FI.T.TXT >PUSHBI O.RDONLY+O.TEXT pla - + ply >SYSCALL FOpen - bcs .9 - - pha - - lda #0 - >STA.G bPrintedBlankLine Reset this flag for the new file - - pla - clc -.9 rts + rts *-------------------------------------- CS.QUIT >LDA.G hBuf beq CS.RUN.CLOSE >SYSCALL FreeMem -CS.RUN.CLOSE ldy #hFILE - lda (pData),y +CS.RUN.CLOSE >LDA.G hFILE beq .8 pha @@ -312,7 +306,6 @@ MSG.USAGE .AS "Usage : CAT File1 [File2...]\r\n" .AS " -A : Show All non printable caracters\r\n" .AS " -N : Number all output lines\r\n" .AZ " -S : Suppress repeated empty output lines\r\n" -MSG.Init .AZ "\e[7l" MSG.LINENUM .AZ "%5D:" MSG.CTRLCHAR .AZ "[%S]" *-------------------------------------- @@ -348,9 +341,6 @@ ASCII >PSTR "NULL" >PSTR "GS" >PSTR "RS" >PSTR "US" -*-------------------------------------- -BytesRead .BS 1 -ByteIndex .BS 1 *-------------------------------------- .DUMMY .OR 0 diff --git a/SYS/KERNEL.S.GP.txt b/SYS/KERNEL.S.GP.txt index 3fe4f756..b78518fc 100644 --- a/SYS/KERNEL.S.GP.txt +++ b/SYS/KERNEL.S.GP.txt @@ -157,6 +157,7 @@ GP.SysCall dec IRQ.InKernel ldy .5+1 lda .6+1 ldx .7+1 + inc IRQ.InKernel jmp GP.Sleep .4 ldx #$FF Self Modified @@ -177,8 +178,7 @@ GP.LibCall dec IRQ.InKernel pla .1 jsr $FFFF SELF MODIFIED - inc IRQ.InKernel - +GP.LibCall.8 inc IRQ.InKernel rts *-------------------------------------- GP.AtkCall dec IRQ.InKernel @@ -190,8 +190,7 @@ GP.AtkCall dec IRQ.InKernel .1 .DA * jsr GO.A2osX - inc IRQ.InKernel - rts + bra GP.LibCall.8 *-------------------------------------- GP.RomCallPushFAC jsr GP.ROMCALL