mirror of
https://github.com/a2stuff/prodos-drivers.git
synced 2025-01-02 16:32:32 +00:00
NSC: Junk, more symbols
This commit is contained in:
parent
e8e6ead1c5
commit
16c6c98124
@ -130,19 +130,21 @@ cloop: iny
|
|||||||
cld
|
cld
|
||||||
bit ROMIN2
|
bit ROMIN2
|
||||||
|
|
||||||
lda #$46 ; reset vector???
|
;; Update reset vector
|
||||||
|
lda #<pre_install
|
||||||
sta $03F2
|
sta $03F2
|
||||||
lda #$10
|
lda #>pre_install
|
||||||
sta $03F3
|
sta $03F3
|
||||||
eor #$A5
|
eor #$A5
|
||||||
sta $03F4
|
sta $03F4
|
||||||
|
|
||||||
lda #$95 ; Ctrl+U
|
lda #$95 ; Ctrl+U (quit 80 col firmware)
|
||||||
jsr COUT
|
jsr COUT
|
||||||
|
|
||||||
ldx #$FF
|
ldx #$FF ; Reset stack
|
||||||
txs
|
txs
|
||||||
sta CLR80VID
|
|
||||||
|
sta CLR80VID ; Reset I/O
|
||||||
sta CLRALTCHAR
|
sta CLRALTCHAR
|
||||||
jsr SETVID
|
jsr SETVID
|
||||||
jsr SETKBD
|
jsr SETKBD
|
||||||
@ -182,14 +184,15 @@ cloop: iny
|
|||||||
;;; --------------------------------------------------
|
;;; --------------------------------------------------
|
||||||
;;; Detect NSC
|
;;; Detect NSC
|
||||||
|
|
||||||
detect_nsc:
|
.proc detect_nsc
|
||||||
;; Preserve date/time
|
;; Preserve date/time
|
||||||
ldy #3 ; copy 4 bytes
|
ldy #3 ; copy 4 bytes
|
||||||
: lda DATELO,y
|
: lda DATELO,y
|
||||||
sta L1197,y
|
sta saved_dt,y
|
||||||
dey
|
dey
|
||||||
bpl :-
|
bpl :-
|
||||||
|
|
||||||
|
;; Check slot ROMs
|
||||||
lda #$CF
|
lda #$CF
|
||||||
ldy #$FF
|
ldy #$FF
|
||||||
sta ld4+2
|
sta ld4+2
|
||||||
@ -197,16 +200,16 @@ detect_nsc:
|
|||||||
sta st4+2
|
sta st4+2
|
||||||
sty st4+1
|
sty st4+1
|
||||||
lda #$00
|
lda #$00
|
||||||
sta L119C
|
sta slot
|
||||||
lda #$03
|
lda #$03
|
||||||
L10DF: ora #$C0
|
L10DF: ora #$C0
|
||||||
sta st1+2
|
sta st1+2
|
||||||
L10E4: sta ld1+2
|
L10E4: sta ld1+2
|
||||||
sta ld2+2
|
sta ld2+2
|
||||||
sta st2+2
|
sta st2+2
|
||||||
lda #$03
|
lda #3
|
||||||
sta L119B
|
sta tries
|
||||||
L10F2: jsr driver
|
try: jsr driver
|
||||||
lda DATELO+1
|
lda DATELO+1
|
||||||
ror a
|
ror a
|
||||||
lda DATELO
|
lda DATELO
|
||||||
@ -215,30 +218,30 @@ L10F2: jsr driver
|
|||||||
rol a
|
rol a
|
||||||
rol a
|
rol a
|
||||||
and #$0F
|
and #$0F
|
||||||
beq L1128
|
beq next
|
||||||
cmp #$0D
|
cmp #$0D
|
||||||
bcs L1128
|
bcs next
|
||||||
lda DATELO
|
lda DATELO
|
||||||
L110B: and #$1F
|
and #$1F
|
||||||
beq L1128
|
beq next
|
||||||
cmp #$20
|
cmp #$20
|
||||||
bcs L1128
|
bcs next
|
||||||
.byte $AD
|
.byte $AD
|
||||||
.byte $93
|
.byte $93
|
||||||
L1115: bbs3 $C9,$1130
|
bbs3 $C9,$1130
|
||||||
bcs L1128
|
bcs next
|
||||||
lda TIMELO
|
lda TIMELO
|
||||||
cmp #$3C
|
cmp #$3C
|
||||||
bcs L1128
|
bcs next
|
||||||
dec L119B
|
dec tries
|
||||||
bne L10F2
|
bne try
|
||||||
.byte $F0
|
.byte $F0
|
||||||
L1127: .byte $75
|
.byte $75
|
||||||
L1128: inc L119C
|
next: inc slot
|
||||||
lda L119C
|
lda slot
|
||||||
cmp #$08
|
cmp #8
|
||||||
bcc L10DF
|
bcc L10DF
|
||||||
bne L1151
|
bne not_found
|
||||||
lda #$C0
|
lda #$C0
|
||||||
ldy #$15
|
ldy #$15
|
||||||
sta ld4+2
|
sta ld4+2
|
||||||
@ -253,8 +256,9 @@ L1128: inc L119C
|
|||||||
bne L10E4
|
bne L10E4
|
||||||
|
|
||||||
;; Restore date/time
|
;; Restore date/time
|
||||||
L1151: ldy #$03
|
not_found:
|
||||||
: lda L1197,y
|
ldy #3
|
||||||
|
: lda saved_dt,y
|
||||||
sta DATELO,y
|
sta DATELO,y
|
||||||
dey
|
dey
|
||||||
bpl :-
|
bpl :-
|
||||||
@ -274,9 +278,11 @@ L1151: ldy #$03
|
|||||||
|
|
||||||
jmp exit
|
jmp exit
|
||||||
|
|
||||||
L1197: .byte 0, 0, 0, 0
|
saved_dt:
|
||||||
L119B: .byte $03
|
.byte 0, 0, 0, 0
|
||||||
L119C: brk
|
tries: .byte 3
|
||||||
|
slot: .byte 0
|
||||||
|
.endproc
|
||||||
|
|
||||||
;;; --------------------------------------------------
|
;;; --------------------------------------------------
|
||||||
;;; Install NSC Date Driver
|
;;; Install NSC Date Driver
|
||||||
@ -353,10 +359,10 @@ loop: lda driver,y
|
|||||||
;;; --------------------------------------------------
|
;;; --------------------------------------------------
|
||||||
|
|
||||||
exit:
|
exit:
|
||||||
;; Twiddle reset vector?
|
;; Update reset vector
|
||||||
lda #$65
|
lda #<quit
|
||||||
sta $03F2
|
sta $03F2
|
||||||
lda #$13
|
lda #>quit
|
||||||
sta $03F3
|
sta $03F3
|
||||||
eor #$A5
|
eor #$A5
|
||||||
sta $03F4
|
sta $03F4
|
||||||
@ -370,7 +376,9 @@ exit:
|
|||||||
ptr := $A5
|
ptr := $A5
|
||||||
len := $A8
|
len := $A8
|
||||||
|
|
||||||
;; Volume Directory Header structure
|
;; Volume Directory Block Header structure
|
||||||
|
prev_block := $00
|
||||||
|
next_block := $02
|
||||||
entry_length := $23
|
entry_length := $23
|
||||||
entries_per_block := $24
|
entries_per_block := $24
|
||||||
header_length := $2B
|
header_length := $2B
|
||||||
@ -437,19 +445,19 @@ next: lda ptr
|
|||||||
clc
|
clc
|
||||||
adc1: adc #$27 ; self-modified: entry_length
|
adc1: adc #$27 ; self-modified: entry_length
|
||||||
sta ptr
|
sta ptr
|
||||||
bcc L1293
|
bcc :+
|
||||||
inc ptr+1
|
inc ptr+1
|
||||||
L1293: inc $A7
|
: inc $A7
|
||||||
lda $A7
|
lda $A7
|
||||||
cmp1: cmp #$0D ; self-modified: entries_per_block
|
cmp1: cmp #$0D ; self-modified: entries_per_block
|
||||||
bcc entry
|
bcc entry
|
||||||
|
|
||||||
lda data_buffer + $2
|
lda data_buffer + next_block
|
||||||
sta read_block_params_block_num
|
sta read_block_params_block_num
|
||||||
lda data_buffer + $3
|
lda data_buffer + next_block + 1
|
||||||
sta read_block_params_block_num+1
|
sta read_block_params_block_num+1
|
||||||
ora read_block_params_block_num
|
ora read_block_params_block_num
|
||||||
beq not_found
|
beq not_found ; last block has next=0
|
||||||
jsr read_block
|
jsr read_block
|
||||||
lda #$00
|
lda #$00
|
||||||
sta $A7
|
sta $A7
|
||||||
@ -591,7 +599,7 @@ lowercase_mask:
|
|||||||
.byte 3 ; param_count
|
.byte 3 ; param_count
|
||||||
unit_num: .byte $60 ; unit_num
|
unit_num: .byte $60 ; unit_num
|
||||||
.addr data_buffer ; data_buffer
|
.addr data_buffer ; data_buffer
|
||||||
block_num: .word 2 ; block_num
|
block_num: .word 2 ; block_num - block 2 is volume directory
|
||||||
.endproc
|
.endproc
|
||||||
read_block_params_unit_num := read_block_params::unit_num
|
read_block_params_unit_num := read_block_params::unit_num
|
||||||
read_block_params_block_num := read_block_params::block_num
|
read_block_params_block_num := read_block_params::block_num
|
||||||
@ -674,7 +682,6 @@ found_self_flag:
|
|||||||
|
|
||||||
suffix: .byte SYSTEM_SUFFIX
|
suffix: .byte SYSTEM_SUFFIX
|
||||||
|
|
||||||
|
|
||||||
self_name:
|
self_name:
|
||||||
PASCAL_STRING "NS.CLOCK.SYSTEM"
|
PASCAL_STRING "NS.CLOCK.SYSTEM"
|
||||||
|
|
||||||
@ -757,38 +764,54 @@ unlock:
|
|||||||
sizeof_driver := * - driver
|
sizeof_driver := * - driver
|
||||||
|
|
||||||
;;; --------------------------------------------------
|
;;; --------------------------------------------------
|
||||||
;;; Junk from here on?
|
;;; Junk from here on...
|
||||||
|
|
||||||
;; ??
|
.byte $b3, $68, $72, $f0, $2a, $2a, $2a, $2a
|
||||||
.byte $B3
|
.byte $2a, $2a, $20, $2f, $52, $41, $4d, $20
|
||||||
|
.byte $8d, $00, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
pla
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $20, $2f
|
||||||
adc ($F0)
|
.byte $43, $4f, $4e, $54, $49, $45, $52, $49
|
||||||
|
.byte $20, $8d, $00, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $03, $2f, $48, $44, $20, $8d
|
||||||
.res 6, $2a
|
.byte $00, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte " /RAM ", $8D, $00
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.res 12, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte " /CONTIERI ", $8D, $00
|
.byte $2a, $2a, $2a, $2a, $6a, $2d, $2a, $2a
|
||||||
.res 7, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte $03, "/HD ", $8D, $00
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.res 27, $2a
|
.byte $2a, $31, $f0, $03, $4c, $43, $3a, $ad
|
||||||
.byte $6a, $2d
|
.byte $3e, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.res 19, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte $31, $f0, $03, $4c, $43, $3a, $ad, $3e
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.res 7, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
L14F4: .res 2, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
L14F6: .res 99, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
L1559: .res 12, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte $CA, $FC, $30, $F0, $07, $C9, $4C, $F0
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.res 120, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte 0, 0, 0
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
lda $3150
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
bne L15EE
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
; 000005e0 2a 2a 2a 2a 2a 00 00 00 ad 50 31 d0 01 2a 2a 2a |*****....P1..***|
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
; 000005f0 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a 2a |****************|
|
.byte $2a, $ca, $fc, $30, $f0, $07, $c9, $4c
|
||||||
|
.byte $f0, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
.byte $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
L15EE: .res 18, $2a
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $00, $00, $00, $ad, $50, $31, $d0
|
||||||
|
.byte $01, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a, $2a, $2a, $2a, $2a
|
||||||
|
.byte $2a, $2a, $2a, $2a
|
||||||
|
Loading…
Reference in New Issue
Block a user