IPCONFIG:retry fix

This commit is contained in:
burniouf 2023-06-15 19:15:36 +02:00
parent f12295ec7c
commit f6cdf228ed
3 changed files with 18 additions and 18 deletions

Binary file not shown.

View File

@ -1,9 +1,14 @@
NEW
AUTO 3,1
*--------------------------------------
DHCP.INIT.OK >LDYA L.MSG.DHCP.NA
>SYSCALL PutS
sec
rts
DHCP.INIT lda IPCFG+S.NETCFG.STATUS
and #S.IPCFG.STATUS.OK
bne .99 Already Configured, exit
bne DHCP.INIT.OK Already Configured, exit
ldx #3
@ -21,25 +26,12 @@ DHCP.INIT lda IPCFG+S.NETCFG.STATUS
dex
bpl .2
clc
rts
.99 >LDYA L.MSG.DHCP.NA
>SYSCALL PutS
sec
rts
*--------------------------------------
DHCP.RUN stz IPCFG+S.NETCFG.STATUS
>PUSHBI S.SOCKET.T.DGRAM
>PUSHBI 0 no protocol
>LIBCALL hLIBTCPIP,LIBTCPIP.Socket
bcc .1
bcs .9
.9 jmp DHCP.RUN.KO
.1 sta hSocket
sta hSocket
>PUSHA
>PUSHW L.SA.LOCAL
>LIBCALL hLIBTCPIP,LIBTCPIP.Bind
@ -58,6 +50,12 @@ DHCP.RUN stz IPCFG+S.NETCFG.STATUS
>LDYA L.MSG.DHCP.CFG1
>SYSCALL PutS
rts
.9 jmp DHCP.RUN.KO
*--------------------------------------
DHCP.RUN stz IPCFG+S.NETCFG.STATUS
>SLEEP
@ -253,6 +251,7 @@ CheckDHCPOffer jsr CheckDHCPXID
php
lda hFrame
>SYSCALL FreeMem
stz hFrame
plp
rts
*--------------------------------------
@ -343,6 +342,7 @@ CheckDHCPAck jsr CheckDHCPXID
php
lda hFrame
>SYSCALL FreeMem
stz hFrame
plp
rts
*--------------------------------------

View File

@ -200,7 +200,7 @@ CS.RUN.SETUP
jsr ETC.ReadFiles
.6 lda bDHCP
bpl .8
bpl .80
jsr DHCP.INIT
bcs CS.RUN.SETUP.RTS
@ -222,7 +222,7 @@ CS.RUN.SETUP
.8 jsr DHCP.QUIT
lda #0
.80 lda #0
sec
CS.RUN.SETUP.RTS