POST 2600, fixes #1

This commit is contained in:
burniouf 2023-06-02 22:31:09 +02:00
parent 77c818cfcb
commit 6ae9b75ac8
15 changed files with 292 additions and 276 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -122,10 +122,10 @@ BSX.MoveHead sta BSX.TargetQTrack
jsr BSX.Wait25600usec jsr BSX.Wait25600usec
ldy BSX.Slotn0 ldy BSX.Slotn0
lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+6,y
lda IO.D2.Ph0Off,y lda IO.D2.Ph0Off,y
lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+4,y lda IO.D2.Ph0Off+4,y
lda IO.D2.Ph0Off+6,y
* lda IO.D2.Ph0Off,y * lda IO.D2.Ph0Off,y

View File

@ -5,8 +5,6 @@ DHCP.INIT lda IPCFG+S.NETCFG.STATUS
and #S.IPCFG.STATUS.OK and #S.IPCFG.STATUS.OK
bne .99 Already Configured, exit bne .99 Already Configured, exit
stz IPCFG+S.NETCFG.STATUS
ldx #3 ldx #3
.1 eor A2osX.TIMER16,x .1 eor A2osX.TIMER16,x
@ -24,7 +22,7 @@ DHCP.INIT lda IPCFG+S.NETCFG.STATUS
bpl .2 bpl .2
clc clc
.9 rts rts
.99 >LDYA L.MSG.DHCP.NA .99 >LDYA L.MSG.DHCP.NA
@ -32,7 +30,9 @@ DHCP.INIT lda IPCFG+S.NETCFG.STATUS
sec sec
rts rts
*-------------------------------------- *--------------------------------------
DHCP.RUN >PUSHBI S.SOCKET.T.DGRAM DHCP.RUN stz IPCFG+S.NETCFG.STATUS
>PUSHBI S.SOCKET.T.DGRAM
>PUSHBI 0 no protocol >PUSHBI 0 no protocol
>LIBCALL hLIBTCPIP,LIBTCPIP.Socket >LIBCALL hLIBTCPIP,LIBTCPIP.Socket
bcc .1 bcc .1
@ -61,9 +61,6 @@ DHCP.RUN >PUSHBI S.SOCKET.T.DGRAM
>SLEEP >SLEEP
lda #3
sta RetryCount
DHCP.RUN.SDISC >PUSHB hSocket DHCP.RUN.SDISC >PUSHB hSocket
>PUSHW L.DHCP.DISC >PUSHW L.DHCP.DISC
>PUSHWI DHCP.DISC.LEN >PUSHWI DHCP.DISC.LEN
@ -75,14 +72,11 @@ DHCP.RUN.SDISC >PUSHB hSocket
jmp DHCP.RUN.KO jmp DHCP.RUN.KO
.1 lda #S.IPCFG.STATUS.SDISC .1 lda #S.IPCFG.STATUS.SDISC
sta IPCFG sta IPCFG+S.NETCFG.STATUS
DHCP.RUN.ROFFER jsr DHCP.RUN.SKT.RECV DHCP.RUN.ROFFER jsr DHCP.RUN.SKT.RECV
bcc .1 bcc .1
dec RetryCount
bne DHCP.RUN.SDISC
lda #1 lda #1
jmp DHCP.RUN.KO jmp DHCP.RUN.KO
@ -90,7 +84,7 @@ DHCP.RUN.ROFFER jsr DHCP.RUN.SKT.RECV
bcs DHCP.RUN.ROFFER bcs DHCP.RUN.ROFFER
lda #S.IPCFG.STATUS.ROFFER lda #S.IPCFG.STATUS.ROFFER
sta IPCFG sta IPCFG+S.NETCFG.STATUS
DHCP.RUN.SREQ >PUSHW L.MSG.DHCP.CFG2 DHCP.RUN.SREQ >PUSHW L.MSG.DHCP.CFG2
ldx #0 ldx #0
@ -111,7 +105,7 @@ DHCP.RUN.SREQ >PUSHW L.MSG.DHCP.CFG2
bcs DHCP.RUN.KO bcs DHCP.RUN.KO
lda #S.IPCFG.STATUS.SREQ lda #S.IPCFG.STATUS.SREQ
sta IPCFG sta IPCFG+S.NETCFG.STATUS
DHCP.RUN.RACK jsr DHCP.RUN.SKT.RECV DHCP.RUN.RACK jsr DHCP.RUN.SKT.RECV
bcc .1 bcc .1
@ -123,7 +117,7 @@ DHCP.RUN.RACK jsr DHCP.RUN.SKT.RECV
bcs DHCP.RUN.RACK bcs DHCP.RUN.RACK
DHCP.RUN.OK lda #S.IPCFG.STATUS.OK DHCP.RUN.OK lda #S.IPCFG.STATUS.OK
sta IPCFG sta IPCFG+S.NETCFG.STATUS
>PUSHW L.IPCFG >PUSHW L.IPCFG
>LIBCALL hLIBTCPIP,LIBTCPIP.SETCFG >LIBCALL hLIBTCPIP,LIBTCPIP.SETCFG
@ -148,9 +142,7 @@ DHCP.RUN.OK lda #S.IPCFG.STATUS.OK
>PUSHBI 8 >PUSHBI 8
>SYSCALL PrintF >SYSCALL PrintF
lda #0 Leave with NO ERROR rts Leave with NO ERROR
sec
rts
DHCP.RUN.KO pha DHCP.RUN.KO pha
>PUSHW L.MSG.DHCP.KO >PUSHW L.MSG.DHCP.KO

View File

@ -203,13 +203,26 @@ CS.RUN.SETUP
bpl .8 bpl .8
jsr DHCP.INIT jsr DHCP.INIT
bcs .8 bcs CS.RUN.SETUP.RTS
jsr DHCP.RUN lda #3
sta RetryCount
.7 jsr DHCP.RUN
bcc .8
dec RetryCount
bne .7
pha
jsr DHCP.QUIT jsr DHCP.QUIT
pla
sec
rts
.8 lda #0 .8 jsr DHCP.QUIT
lda #0
sec sec
CS.RUN.SETUP.RTS CS.RUN.SETUP.RTS

View File

@ -199,7 +199,7 @@ hLIBCRYPT .BS 1
OptionList .AS "Dd" OptionList .AS "Dd"
OptionVars .DA #bText,#bText OptionVars .DA #bText,#bText
*-------------------------------------- *--------------------------------------
MSG.USAGE .AZ "Usage : MD4 [ -d input text | input file ]\r\n" MSG.USAGE .CZ "Usage : MD4 [ -d input text | input file ]\r\n"
*-------------------------------------- *--------------------------------------
.DUMMY .DUMMY
.OR 0 .OR 0

View File

@ -184,7 +184,7 @@ CS.END
OptionList .AS "Dd" OptionList .AS "Dd"
OptionVars .DA #bText,#bText OptionVars .DA #bText,#bText
*-------------------------------------- *--------------------------------------
MSG.USAGE .AZ "Usage : MD5 [ -d input text | input file ]\r\n" MSG.USAGE .CZ "Usage : MD5 [ -d input text | input file ]\r\n"
*-------------------------------------- *--------------------------------------
.DUMMY .DUMMY
.OR 0 .OR 0

View File

@ -83,8 +83,10 @@ CS.RUN.LOOP lda bPipe If reading from pipe
>SYSCALL GetChar >SYSCALL GetChar
bcs .9 I/O error bcs .9 I/O error
cmp #$03 Ctrl-C cmp #$03 Ctrl-C
beq .9 beq .9
cmp #$13 Ctrl-S cmp #$13 Ctrl-S
bne .1 bne .1
@ -113,7 +115,8 @@ CS.RUN.LOOP lda bPipe If reading from pipe
.9 sec .9 sec
CS.RUN.LOOP.RTS rts CS.RUN.LOOP.RTS rts
*-------------------------------------- *--------------------------------------
CS.RUN.CheckArgs jsr CS.RUN.NextArg CS.RUN.CheckArgs
jsr CS.RUN.NextArg
bcs .4 bcs .4
lda (ZPPtr1) lda (ZPPtr1)
@ -207,7 +210,9 @@ CS.RUN.OPEN >PUSHYA
>PUSHWZ Aux type >PUSHWZ Aux type
>SYSCALL FOpen >SYSCALL FOpen
bcs .9 bcs .9
sta hFile sta hFile
.9 rts .9 rts
*-------------------------------------- *--------------------------------------
CS.RUN.ISATTY ldy #S.PS.hStdOut CS.RUN.ISATTY ldy #S.PS.hStdOut
@ -218,39 +223,52 @@ CS.RUN.ISATTY ldy #S.PS.hStdOut
>STYA ZPPtr1 >STYA ZPPtr1
lda (ZPPtr1) lda (ZPPtr1)
beq .9 beq .9
inc bIsTTY inc bIsTTY
.9 rts .9 rts
*-------------------------------------- *--------------------------------------
CS.QUIT lda hFile CS.QUIT lda hFile
beq .1 beq .1
>SYSCALL FClose >SYSCALL FClose
.1 lda hBuf .1 lda hBuf
beq .8 beq .8
>SYSCALL FreeMem >SYSCALL FreeMem
.8 clc .8 clc
rts rts
*-------------------------------------- *--------------------------------------
CS.RUN.PRINTBYTE pha CS.RUN.PRINTBYTE
pha
lda bNewLine lda bNewLine
beq .2 beq .2
stz bNewLine stz bNewLine
>PUSHW L.MSG.LINENUM >PUSHW L.MSG.LINENUM
>PUSHW LineCount >PUSHW LineCount
>PUSHBI 2 >PUSHBI 2
>SYSCALL PrintF >SYSCALL PrintF
.2 pla .2 pla
pha pha
>SYSCALL PutChar >SYSCALL PutChar
pla pla
cmp #C.CR cmp #C.CR
bne .9 bne .9
lda bIsTTY lda bIsTTY
beq .4 beq .4
lda #C.LF lda #C.LF
>SYSCALL PutChar >SYSCALL PutChar
.4 inc bNewLine .4 inc bNewLine
inc LineCount inc LineCount
bne .9 bne .9
inc LineCount+1 inc LineCount+1
.9 rts .9 rts
*-------------------------------------- *--------------------------------------
@ -262,9 +280,9 @@ CS.END
OptionList .AS "x" OptionList .AS "x"
OptionList.Cnt .EQ *-OptionList OptionList.Cnt .EQ *-OptionList
*-------------------------------------- *--------------------------------------
MSG.USAGE .AS "Usage : NL <File> or CMD|NL" MSG.USAGE .CS "Usage : NL <File> or CMD|NL"
MSG.CRLF .AZ "\r\n" MSG.CRLF .CZ "\r\n"
MSG.LINENUM .AZ "%5D " MSG.LINENUM .CZ "%5D "
*-------------------------------------- *--------------------------------------
.DUMMY .DUMMY
.OR 0 .OR 0

View File

@ -425,13 +425,13 @@ IsDigit cmp #'0'
rts rts
*-------------------------------------- *--------------------------------------
CS.END CS.END
MSG.READ.KO .AZ "DS1216E Not Detected.\r\n" MSG.READ.KO .CZ "DS1216E Not Detected.\r\n"
MSG.READ.OK1 .AZ "DS1216E Detected : /OSC=%d, /RST=%d, mode=" MSG.READ.OK1 .CZ "DS1216E Detected : /OSC=%d, /RST=%d, mode="
MSG.READ.OK2.12 .AZ "am/pm" MSG.READ.OK2.12 .CZ "am/pm"
MSG.READ.OK2.24 .AZ "24h" MSG.READ.OK2.24 .CZ "24h"
MSG.READ.OK3 .AZ "\r\nCurrent Date/Time : " MSG.READ.OK3 .CZ "\r\nCurrent Date/Time : "
MSG.USAGE .AS "\r\nTo Reset the chip and set clock, type:\r\nNSCUTIL YY/MM/DD,hh:mm:ss" MSG.USAGE .CS "\r\nTo Reset the chip and set clock, type:\r\nNSCUTIL YY/MM/DD,hh:mm:ss"
MSG.CRLF .AZ "\r\n" MSG.CRLF .CZ "\r\n"
DS121x.SIG .HS 5CA33AC55CA33AC5 Reverted 7->0 DS121x.SIG .HS 5CA33AC55CA33AC5 Reverted 7->0
*-------------------------------------- *--------------------------------------
DS.START DS.START

View File

@ -34,7 +34,7 @@ Flt.Table.cbLO .EQ $1368 K.FLT.MAX
Flt.Table.cbHI .EQ $136C K.FLT.MAX Flt.Table.cbHI .EQ $136C K.FLT.MAX
*-------------------------------------- *--------------------------------------
S.Table.hSID .EQ $1370 K.USR.MAX S.Table.hSID .EQ $1370 K.USR.MAX
S.Table.hFile .EQ $1278 K.USR.MAX S.Table.hFile .EQ $1378 K.USR.MAX
*-------------------------------------- *--------------------------------------
PS.Table.PID .EQ $1380 K.PS.MAX PS.Table.PID .EQ $1380 K.PS.MAX
PS.Table.hPS .EQ $13A0 K.PS.MAX PS.Table.hPS .EQ $13A0 K.PS.MAX

View File

@ -167,10 +167,10 @@ D2.MoveHead >PULLB D2.TargetQTrack
jsr D2.Wait25600usec jsr D2.Wait25600usec
ldy D2.Slotn0 ldy D2.Slotn0
lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+6,y
lda IO.D2.Ph0Off,y lda IO.D2.Ph0Off,y
lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+4,y lda IO.D2.Ph0Off+4,y
lda IO.D2.Ph0Off+6,y
* lda IO.D2.Ph0Off,y * lda IO.D2.Ph0Off,y

View File

@ -716,19 +716,12 @@ XRW.TrackSelect lda #2
ora A2L ora A2L
tay y = n0/n2 tay y = n0/n2
iny lda IO.D2.Ph0On,y PhOn 0/2 for Head0 or 1/3 for Head1
jsr XRW.Ph04Off lda IO.D2.Ph0On+4,y
* lda IO.D2.Ph0On,y
* lda IO.D2.Ph0On+4,y
jsr XRW.Wait100usec jsr XRW.Wait100usec
dey jsr XRW.AllPhOff
jsr XRW.Ph04Off
*
* lda IO.D2.Ph0Off,y
* lda IO.D2.Ph0Off+4,y
lda XRW.AddrField.T lda XRW.AddrField.T
sta XRW.D2Trk-1,x sta XRW.D2Trk-1,x
@ -844,11 +837,11 @@ XRW.SeekYA sta XRW.D2Trk-1,x will be current track at the end
jsr XRW.Wait25600usec jsr XRW.Wait25600usec
ldy A2L XRW.AllPhOff ldy A2L
lda IO.D2.Ph0Off,y
lda IO.D2.Ph0Off+2,y lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+6,y
XRW.Ph04Off lda IO.D2.Ph0Off,y
lda IO.D2.Ph0Off+4,y lda IO.D2.Ph0Off+4,y
lda IO.D2.Ph0Off+6,y
* lda IO.D2.Ph0Off,y * lda IO.D2.Ph0Off,y

View File

@ -76,8 +76,8 @@ CS.DOEVENT sec
rts rts
*-------------------------------------- *--------------------------------------
CS.END CS.END
MSG.USAGE .AZ "Usage: insdrv file.drv <args>" MSG.USAGE .CZ "Usage: insdrv file.drv <args>"
MSG.LOAD .AZ "INSDRV:Loading %s...\r\n" MSG.LOAD .CZ "INSDRV:Loading %s...\r\n"
*-------------------------------------- *--------------------------------------
MAN MAN
SAVE usr/src/sbin/insdrv.s SAVE usr/src/sbin/insdrv.s

View File

@ -325,10 +325,10 @@ BB.FX2.SeekReadD2
jsr BB.Wait100usecA jsr BB.Wait100usecA
ldy ROM.D2.Slotn0 ldy ROM.D2.Slotn0
lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+6,y
lda IO.D2.Ph0Off,y lda IO.D2.Ph0Off,y
lda IO.D2.Ph0Off+2,y
lda IO.D2.Ph0Off+4,y lda IO.D2.Ph0Off+4,y
lda IO.D2.Ph0Off+6,y
* lda IO.D2.Ph0Off,y * lda IO.D2.Ph0Off,y