mirror of
https://github.com/bobbimanners/emailler.git
synced 2024-09-26 03:55:26 +00:00
setmac routine is now slot-independent
This commit is contained in:
parent
bc29b3621e
commit
238fc5de49
@ -160,13 +160,20 @@ Main1: cld
|
|||||||
.byte $8D ; CR
|
.byte $8D ; CR
|
||||||
hasc "Uthernet-II SETMAC Utility"
|
hasc "Uthernet-II SETMAC Utility"
|
||||||
.byte $8D,$00 ; CR, done
|
.byte $8D,$00 ; CR, done
|
||||||
|
lda #5 ; Slot 5
|
||||||
jsr setmac
|
jsr setmac
|
||||||
jmp NextSys
|
jmp NextSys
|
||||||
.endproc
|
.endproc
|
||||||
.proc setmac
|
.proc setmac
|
||||||
; Set the MAC address on the Uthernet-II
|
; Set the MAC address on the Uthernet-II
|
||||||
; TODO: Hard-coded for slot 5.
|
; Expects slot number in A
|
||||||
ldy $d5 ; Slot 5 mode reg offset
|
asl
|
||||||
|
asl
|
||||||
|
asl
|
||||||
|
asl
|
||||||
|
clc
|
||||||
|
adc #$85
|
||||||
|
tay ; Mode register offset
|
||||||
lda #$80 ; Reset W5100
|
lda #$80 ; Reset W5100
|
||||||
sta $bfff,y ; Store in MODE register
|
sta $bfff,y ; Store in MODE register
|
||||||
lda #$03 ; Address autoinc, indirect
|
lda #$03 ; Address autoinc, indirect
|
||||||
|
Loading…
Reference in New Issue
Block a user