mirror of
https://github.com/A2osX/A2osX.git
synced 2025-01-10 02:36:59 +00:00
Kernel 0.93++
This commit is contained in:
parent
581b82e934
commit
5e329c153e
Binary file not shown.
@ -85,9 +85,10 @@ CS.RUN >LIBCALL hLIBTCPIP,LIBTCPIP.GETCFG
|
||||
cmp #3
|
||||
bne CS.RUN.ERR
|
||||
jmp CS.RUN.ADD
|
||||
CS.RUN.ERR >PUSHBI 0
|
||||
>LDYA L.MSG.Usage
|
||||
>SYSCALL printf
|
||||
|
||||
CS.RUN.ERR >PUSHW L.MSG.Usage
|
||||
>PUSHBI 0
|
||||
>SYSCALL printf2
|
||||
lda #E.SYN
|
||||
sec
|
||||
rts
|
||||
@ -106,21 +107,27 @@ CS.RUN.QUERY jsr Init.Timeout
|
||||
cmp #3
|
||||
beq .9
|
||||
bra .1
|
||||
.2 ldx #5
|
||||
ldy #DST.MAC+5
|
||||
.3 >PUSHB (pData),y
|
||||
dey
|
||||
dex
|
||||
bpl .3
|
||||
ldx #3
|
||||
ldy #DST.IP+3
|
||||
|
||||
.2 >PUSHW L.MSG2
|
||||
|
||||
ldx #4
|
||||
ldy #DST.IP
|
||||
|
||||
.4 >PUSHB (pData),y
|
||||
dey
|
||||
iny
|
||||
dex
|
||||
bpl .4
|
||||
bne .4
|
||||
|
||||
ldx #6
|
||||
ldy #DST.MAC
|
||||
|
||||
.3 >PUSHB (pData),y
|
||||
iny
|
||||
dex
|
||||
bne .3
|
||||
|
||||
>PUSHBI 10
|
||||
>LDYA L.MSG2
|
||||
>SYSCALL printf
|
||||
>SYSCALL printf2
|
||||
.8 lda #0
|
||||
.9 sec
|
||||
rts
|
||||
@ -156,28 +163,31 @@ CS.RUN.DUMP >LIBCALL hLIBTCPIP,LIBTCPIP.ARP.GETCACHE
|
||||
.1 lda (ZPPTR1)
|
||||
beq .4
|
||||
|
||||
ldy #S.ARPCACHE.IP+4
|
||||
|
||||
.2 dey
|
||||
>PUSHB (ZPPTR1),y
|
||||
cpy #S.ARPCACHE.IP
|
||||
bne .2
|
||||
|
||||
ldy #S.ARPCACHE.MAC+6
|
||||
|
||||
.3 dey
|
||||
>PUSHB (ZPPTR1),y
|
||||
cpy #S.ARPCACHE.MAC
|
||||
bne .3
|
||||
|
||||
>PUSHW L.MSG1
|
||||
|
||||
>PUSHB (ZPPTR1)
|
||||
|
||||
ldy #S.ARPCACHE.TTL+1
|
||||
>PUSHB (ZPPTR1),y
|
||||
dey
|
||||
>PUSHB (ZPPTR1),y
|
||||
>PUSHB (ZPPTR1)
|
||||
|
||||
ldy #S.ARPCACHE.MAC
|
||||
|
||||
.3 >PUSHB (ZPPTR1),y
|
||||
iny
|
||||
cpy #S.ARPCACHE.MAC+6
|
||||
bne .3
|
||||
|
||||
ldy #S.ARPCACHE.IP
|
||||
|
||||
.2 >PUSHB (ZPPTR1),y
|
||||
iny
|
||||
cpy #S.ARPCACHE.IP+4
|
||||
bne .2
|
||||
|
||||
>PUSHBI 13
|
||||
>LDYA L.MSG1
|
||||
>SYSCALL printf
|
||||
>SYSCALL printf2
|
||||
|
||||
.4 lda ZPPTR1
|
||||
clc
|
||||
|
@ -67,6 +67,7 @@ CS.RUN
|
||||
lda ArgIndex
|
||||
>SYSCALL ArgV
|
||||
bcs .7
|
||||
|
||||
>STYA ZPPtr1
|
||||
|
||||
lda (ZPPtr1)
|
||||
@ -74,33 +75,32 @@ CS.RUN
|
||||
bne .2
|
||||
jsr CS.RUN.CheckOpt
|
||||
bcc .1
|
||||
.99 >PUSHBI 0
|
||||
>LDYA L.MSG.USAGE
|
||||
>SYSCALL printf
|
||||
|
||||
.99 >PUSHW L.MSG.USAGE
|
||||
>PUSHBI 0
|
||||
>SYSCALL printf2
|
||||
lda #E.SYN
|
||||
sec
|
||||
.9 rts
|
||||
|
||||
.2 lda hFile1
|
||||
bne .3
|
||||
|
||||
jsr CS.RUN.OPEN
|
||||
bcs .9
|
||||
|
||||
sta hFile1
|
||||
>LDYAI 256
|
||||
>SYSCALL GetMem
|
||||
bcs .9
|
||||
>STYA ZPBufPtr1
|
||||
stx hBuf1
|
||||
|
||||
bra .1
|
||||
|
||||
.3 lda hFile2
|
||||
bne .4
|
||||
|
||||
jsr CS.RUN.OPEN
|
||||
bcs .9
|
||||
|
||||
sta hFile2
|
||||
>LDYAI 256
|
||||
>SYSCALL GetMem
|
||||
bcs .9
|
||||
>STYA ZPBufPtr2
|
||||
stx hBuf2
|
||||
|
||||
bra .1
|
||||
|
||||
.4 bit bSkip1
|
||||
@ -110,18 +110,36 @@ CS.RUN
|
||||
sec
|
||||
ror bSkip1
|
||||
bra .1
|
||||
|
||||
.5 bit bSkip2
|
||||
bmi .99
|
||||
|
||||
sta bSkip2
|
||||
jsr CS.RUN.SEEK
|
||||
bcs .9
|
||||
|
||||
sec
|
||||
ror bSkip2
|
||||
jmp .1
|
||||
|
||||
.7 lda hFile2
|
||||
beq .99
|
||||
lda hFile1
|
||||
beq .99
|
||||
|
||||
.8 >LDYAI 256
|
||||
>SYSCALL GetMem
|
||||
bcs .9
|
||||
|
||||
>STYA ZPBufPtr1
|
||||
stx hBuf1
|
||||
|
||||
>LDYAI 256
|
||||
>SYSCALL GetMem
|
||||
bcs .9
|
||||
|
||||
>STYA ZPBufPtr2
|
||||
stx hBuf2
|
||||
*--------------------------------------
|
||||
CS.RUN.LOOP ldy #S.PS.hStdIn
|
||||
lda (pPS),y
|
||||
@ -225,14 +243,16 @@ CS.RUN.READ2 >PUSHWI 256
|
||||
rts
|
||||
*--------------------------------------
|
||||
CS.RUN.Print phy
|
||||
>PUSHB (ZPBufPtr2),y
|
||||
>PUSHB (ZPBufPtr1),y
|
||||
|
||||
>PUSHW L.MSG.DIFF
|
||||
>PUSHW Offset
|
||||
tya
|
||||
>PUSHA
|
||||
>PUSHW Offset
|
||||
>PUSHB (ZPBufPtr1),y
|
||||
>PUSHB (ZPBufPtr2),y
|
||||
>PUSHBI 5
|
||||
>LDYA L.MSG.DIFF
|
||||
>SYSCALL printf
|
||||
|
||||
ply
|
||||
rts
|
||||
*--------------------------------------
|
||||
|
@ -74,9 +74,10 @@ CS.RUN.IPOK ldy #S.PS.ARGC
|
||||
|
||||
.1 cmp #2
|
||||
beq CS.RUN.ADD
|
||||
|
||||
>PUSHW L.MSG.USAGE
|
||||
>PUSHBI 0
|
||||
>LDYA L.MSG.USAGE
|
||||
>SYSCALL printf
|
||||
>SYSCALL printf2
|
||||
|
||||
lda #E.SYN
|
||||
sec
|
||||
@ -120,37 +121,44 @@ CS.RUN.DUMP >LIBCALL hLIBTCPIP,LIBTCPIP.DNS.GetCache
|
||||
.1 lda (ZPPTR1)
|
||||
beq .6
|
||||
|
||||
ldy #S.DNSCACHE.TTL+4
|
||||
.2 dey
|
||||
lda (ZPPTR1),y
|
||||
>PUSHA
|
||||
cpy #S.DNSCACHE.TTL
|
||||
bne .2
|
||||
ldy #S.DNSCACHE.IP+4
|
||||
.3 dey
|
||||
lda (ZPPTR1),y
|
||||
>PUSHA
|
||||
cpy #S.DNSCACHE.IP
|
||||
bne .3
|
||||
ldy #S.DNSCACHE.hNAME
|
||||
lda (ZPPTR1),y
|
||||
>SYSCALL GetMemPtr
|
||||
>PUSHYA
|
||||
>PUSHW L.MSG1
|
||||
ldx #0
|
||||
lda (ZPPTR1) Entry Status
|
||||
bmi .5
|
||||
|
||||
asl
|
||||
tax
|
||||
|
||||
.5 >PUSHW L.MSG1.Status,x
|
||||
|
||||
ldy #S.DNSCACHE.ID
|
||||
>PUSHB (ZPPTR1),y
|
||||
iny
|
||||
>PUSHB (ZPPTR1),y
|
||||
|
||||
ldx #0
|
||||
lda (ZPPTR1) Entry Status
|
||||
bmi .5
|
||||
asl
|
||||
tax
|
||||
.5 >PUSHW L.MSG1.Status,x
|
||||
ldy #S.DNSCACHE.hNAME
|
||||
lda (ZPPTR1),y
|
||||
>SYSCALL GetMemPtr
|
||||
>PUSHYA
|
||||
|
||||
ldy #S.DNSCACHE.IP+4
|
||||
|
||||
.3 dey
|
||||
lda (ZPPTR1),y
|
||||
>PUSHA
|
||||
cpy #S.DNSCACHE.IP
|
||||
bne .3
|
||||
|
||||
|
||||
ldy #S.DNSCACHE.TTL+4
|
||||
.2 dey
|
||||
lda (ZPPTR1),y
|
||||
>PUSHA
|
||||
cpy #S.DNSCACHE.TTL
|
||||
bne .2
|
||||
|
||||
>PUSHBI 14
|
||||
>LDYA L.MSG1
|
||||
>SYSCALL printf
|
||||
>SYSCALL printf2
|
||||
|
||||
.6 lda ZPPTR1
|
||||
clc
|
||||
|
Loading…
x
Reference in New Issue
Block a user