antoine-source/c2p4/c2p4.s
Antoine Vignau 0498bcc0c9 Mass upload
of a couple of (working) disassemblies
2020-11-10 11:31:13 +01:00

4875 lines
50 KiB
ArmAsm

*
* Copy II Plus v4.4c
*
* (c) 1984, Central Point Software
* (s) 2019, Brutal Deluxe Software
*
*
typ bin
org $800
mx %11
lst off
*----------------------------
*--- Copy II Plus equates
* see at code end
*fgOUTPUT = $02fe
*SLOT16 = $02ff
fgCOMMAND = $0358 ; 00=edit, 01=copy
*--- Firmware equates
SOFTEV EQU $03F2
PWREDUP EQU $03F4
KVERSION EQU $BFFF
KBD EQU $C000
KBDSTROBE EQU $C010
PRNTAX EQU $F941
PRBL2 EQU $F94A
UP EQU $FC1A
VTAB EQU $FC22
VTABZ EQU $FC24
HOME EQU $FC58
CLREOL EQU $FC9C
WAIT EQU $FCA8
RDKEY EQU $FD0C
KEYIN EQU $FD1B
GETLN1 EQU $FD6F
CROUT EQU $FD8E
PRBYTE EQU $FDDA
PRHEX EQU $FDE3
COUT EQU $FDED
COUT1 EQU $FDF0
SETINV EQU $FE80
SETNORM EQU $FE84
MONZ EQU $FF69
GETNUM EQU $FFA7
*----------------------------
* DB $B1
* DB $B2
* DB $B3
jmp L0808
L0803 DB $B4
L0804 DB $B5
L0805 DB $B6
L0806 DB $B7
DB $B8
L0808 LDA #$60
STA SLOT16
JMP L0900
L0810 DB $01
L0811 DB $03
L0812 DB $1A
L0813 DB $10
L0814 DB $FE
L0815 DB $FF
L0816 DB $01
L0817 DB $7F
L0818 DB $00
L0819 DB $00
L081A DB $0B
L081B DB $01
L081C DB $00
L081D DB $00
L081E DB $D5
L081F DB $AA
DB $96
DB $00
DB $00
DB $00
DB $00
DB $AA
DB $AA
DB $00
DB $00
DB $DE
DB $AA
DB $00
L082C DB $D5
L082D DB $AA
DB $AD
DB $DE
DB $AA
DB $00
L0832 DB $D5
DB $AA
DB $96
DB $00
DB $00
DB $00
DB $00
DB $AA
DB $AA
DB $00
DB $00
DB $DE
DB $AA
DB $00
L0840 DB $0B
L0841 DB $01
L0842 DB $02
L0843 DB $01
L0844 DB $00
L0845 DB $DE
L0846 DB $AA
L0847 DB $6B
L0848 DB $00
L0849 DB $00
L084A DB $04
L084B DB $10
L084C DB $02
L084D DB $0C
L084E DB $01
L084F DB $00
L0850 DB $40
L0851 DB $01
L0852 DB $0B
L0853 DB $00
L0854 DB $00
L0855 DB $08
L0856 DB $1F
L0857 DB $01
L0858 DB $01
L0859 DB $00
L085A DB $3B
L085B DB $00
L085C DB $01
L085D DB $01
L085E DB $00
L085F DB $00
L0860 DB $10
L0861 DB $00
L0862 DB $07
L0863 DB $08
L0864 DB $01
L0865 DB $01
L0866 DB $00
DB $B7
DB $B9
DB $BA
DB $BB
DB $BC
DB $BD
DB $BE
DB $BF
DB $CB
DB $CD
DB $CE
DB $CF
DB $D3
DB $D6
DB $D7
DB $D9
DB $DA
DB $DB
DB $DC
DB $DD
DB $DE
DB $DF
DB $E5
DB $E6
DB $E7
DB $E9
DB $EA
DB $EB
DB $EC
DB $ED
DB $EE
DB $EF
DB $F2
DB $F3
DB $F4
DB $F5
DB $F6
DB $F7
DB $F9
DB $FA
DB $FB
DB $FC
DB $FD
DB $FE
DB $FF
DB $FF
DB $FF
*--- Denibblize table
L0896 DB $00
DB $01
DB $FF
DB $FF
DB $02
DB $03
DB $FF
DB $04
DB $05
DB $06
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $07
DB $08
DB $FF
DB $FF
DB $FF
DB $09
DB $0A
DB $0B
DB $0C
DB $0D
DB $FF
DB $FF
DB $0E
DB $0F
DB $10
DB $11
DB $12
DB $13
DB $FF
DB $14
DB $15
DB $16
DB $17
DB $18
DB $19
DB $1A
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $1B
DB $FF
DB $1C
DB $1D
DB $1E
DB $FF
DB $FF
DB $FF
DB $1F
DB $FF
DB $FF
DB $20
DB $21
DB $FF
DB $22
DB $23
DB $24
DB $25
DB $26
DB $27
DB $28
DB $FF
DB $FF
DB $FF
DB $FF
DB $FF
DB $29
DB $2A
DB $2B
DB $FF
DB $2C
DB $2D
DB $2E
DB $2F
DB $30
DB $31
DB $32
DB $FF
DB $FF
DB $33
DB $34
DB $35
DB $36
DB $37
DB $38
DB $FF
DB $39
DB $3A
DB $3B
DB $3C
DB $3D
DB $3E
DB $3F
L0900 JMP L2874
L0903 DB $D5
DB $AA
DB $96
DB $00
DB $00
DB $00
DB $00
DB $AA
DB $AA
DB $00
DB $00
DB $DE
DB $AA
DB $00
DB $D5
DB $AA
DB $AD
DB $DE
DB $AA
DB $00
DB $D5
DB $AA
DB $96
DB $00
DB $00
DB $00
DB $00
DB $AA
DB $AA
DB $00
DB $00
DB $DE
DB $AA
DB $00
L0925 DB $00
DB $00
DB $00
DB $00
DB $00
DB $00
L092B LDA L0811
STA $037C
LDA #$00
STA $034B
JSR L0AEF
L0939 LDA $037D
STA $04
JSR L1D9F
LDA #$D7
STA $0354
JSR L1091
LDA $037D
AND #$F0
TAX
LDA $C08D,X
LDA $C08E,X
BPL L0961
LDY $08
LDA #$04
STA L0925,Y
JMP L0ACB
L0961 LDY $17
LDA $C08D,X
LDA $C08E,X
LDA #$FF
STA $C08F,X
CMP $C08C,X
JSR L0AEE
LDA ($00),Y
ORA #$80
NOP
NOP
L097A STA $C08D,X
CMP $C08C,X
CPY $00
L0982 INY
BNE L09A6
INC $01
LDA ($00),Y
NOP
BEQ L09CD
ORA #$80
STA $C08D,X
CMP $C08C,X
JMP L0982
L0997 ORA #$80 ; not called?
STA $C08D,X
CMP $C08C,X
NOP
NOP
L09A1 JMP L0982
L09A4 NOP
L09A5 NOP
L09A6 LDA ($00),Y
BEQ L09CD
BPL L09B1
CPY $00
JMP L097A
L09B1 ORA #$80
BIT $00
STA $C08D,X
CMP $C08C,X
NOP
NOP
L09BD JMP L0982
L09C0 NOP
L09C1 NOP
BIT $00
STA $C08D,X
CMP $C08C,X
JMP L0982
L09CD LDA $C08E,X
LDA $C08C,X
LDA #$00
STA $034C
LDA $C088,X
LDA KBD
CMP #$9B ; escape
BNE L09F2
LDA KBDSTROBE
PLA
PLA
LDA #$00
STA $0357
JSR L2A23
JMP L2874
L09F2 LDY $08
LDA L0925,Y
CMP #$02
BEQ L0A00
LDA L0857
BNE L0A03
L0A00 JMP L0B36
L0A03 LDA #$D6
STA $0354
JSR L1C63
LDA L084C
CMP #$01
BNE L0A63
JSR L0B3F
BCS L0A28
LDY $08
LDA L0925,Y
CMP #$05
BCC L0A60
LDA #$00
STA L0925,Y
JMP L0A60
L0A28 LDA L085B
BEQ L0A51
LDA L0925
BNE L0A37
LDA #$06
STA L0925
L0A37 LDA $034C
CMP #$FF
BNE L0A46
LDA #$00
STA $037C
JMP L0AD4
L0A46 LDA $037C
BPL L0A4E
JMP L0B36
L0A4E JMP L0939
L0A51 LDY $08
LDA L0925,Y
BNE L0AD4
LDA #$05
STA L0925
JMP L0AD4
L0A60 JMP L0B36
L0A63 LDA $0F
STA $14
LDA $0E
SEC
SBC #$01
STA $13
BCS L0A72
DEC $14
L0A72 LDY #$00
LDA ($13),Y
EOR ($0E),Y
AND #$7F
BNE L0A82
INC $0E
BNE L0A82
INC $0F
L0A82 DEC $13
LDA $13
CMP #$FF
BNE L0A8C
DEC $14
L0A8C LDA ($13),Y
EOR ($0E),Y
AND #$7F
BNE L0A9A
INC $0E
BNE L0A9A
INC $0F
L0A9A LDA L081A
STA $19
LDA #$00
STA $17
LDA #$20
STA $13
L0AA7 LDY #$00
L0AA9 LDA $C08C,X
BPL L0AA9
DEC $17
BNE L0AB6
DEC $13
BEQ L0ADF
L0AB6 EOR ($0E),Y
AND #$7F
BNE L0AA7
INY
CPY $19
BNE L0AA9
LDY $08
LDA #$00
STA L0925,Y
JMP L0B36
L0ACB LDY $08
LDA L0925,Y
CMP #$05
BNE L0B36
L0AD4 DEC $037C
BMI L0B36
JSR L11EC
JMP L0939
L0ADF LDY $08
LDA L0925,Y
BNE L0ACB
LDA #$05
STA L0925,Y
JMP L0ACB
L0AEE RTS
L0AEF LDA L084E
CMP #$02
BEQ L0B0F
LDA #$4C
STA L09A1
STA L09BD
LDA #<L0982
STA L09A1+1
STA L09BD+1
LDA #>L0982
STA L09A1+2
STA L09BD+2
RTS
L0B0F LDA #$EA
STA L09A1
STA L09BD
STA L09A1+1
STA L09BD+1
LDA #$4C
STA L09A1+2
STA L09BD+2
LDA #<L0982
STA L09A4
STA L09C0
LDA #>L0982
STA L09A5
STA L09C1
RTS
L0B36 LDA #$00
STA $0354
JSR L1C63
RTS
L0B3F LDA L0925
CMP #$02
BNE L0B48
CLC
RTS
L0B48 LDA #$7A
STA $16
STA $03
LDA #$00
STA $02
LDA #$45
STA $0378
LDA $037D
STA $04
JSR L0DAA
LDA L0803
STA $00
LDA L0804
STA $01
LDA L0806
STA $17
L0B6E LDY #$00
LDX #$00
L0B72 LDA ($00),Y
EOR ($02),Y
AND #$7F
BEQ L0B98
INC $02
BNE L0B6E
INC $03
LDA $03
CMP #$99
BCS L0B88
BCC L0B6E
L0B88 SEC
LDA L0925
CMP #$01
BEQ L0B95
LDA #$05
STA L0925
L0B95 JMP L0BAA
L0B98 INX
INY
CPX L0860
BNE L0B72
LDA $02
STA $0350
LDA $03
STA $0351
CLC
L0BAA LDA #$8B
STA $0378
LDA #$34
STA $16
PHP
JSR L0BCE
BCS L0BC8
LDA $034F
BNE L0BC8
LDA $034E
CMP L085C
BCS L0BC8
PLP
RTS
L0BC8 PLP
DEC $037C
SEC
RTS
L0BCE BCS L0C0D
LDY #$00
LDX #$00
LDA L0803
STA $00
LDA L0804
STA $01
LDA $03
CLC
ADC L0813
STA $03
CMP #$BF
BCC L0BED
JMP L0D46
L0BED LDA ($00),Y
EOR ($02),Y
AND #$7F
BEQ L0C24
INC $02
BNE L0C06
INC $03
LDA $03
SEC
SBC $0351
CMP L0812
BCS L0C0D
L0C06 LDY #$00
LDX #$00
JMP L0BED
L0C0D LDA #$00
STA $034F
LDA #$20
STA $034E
LDA #$FF
STA $034B
LDA #$CF
STA $034D
JMP L0CF3
L0C24 INX
INY
CPX L0860
BCC L0BED
LDA $02
SEC
SBC $0350
STA $0350
LDA $03
SBC $0351
STA $0351
LDA L081B
BEQ L0C70
LDA #$04
STA $22
LDA #$00
STA $24
LDA #$0E
STA $25
JSR VTABZ
LDA #$1A
STA $24
LDA $0351
LDX $0350
JSR PRNTAX
LDA L0925
CMP #$05
BNE L0C70
LDA #$00
STA L0925
LDA #$FF
STA $034C
CLC
RTS
L0C70 LDA L085B
BEQ L0C78
JMP L0C7A
L0C78 CLC
RTS
L0C7A LDA $034B
BEQ L0C86
LDA #$FF
STA $037C
SEC
RTS
L0C86 LDA $08
CLC
ROL
TAY
LDA $0350
SEC
SBC $0341,Y
STA $034E
LDA $0351
SBC $0342,Y
STA $034F
BCS L0CB9
LDA #$00
SEC
SBC $034E
STA $034E
LDA #$00
SBC $034F
STA $034F
LDA #$CF
STA $034D
JMP L0CBE
L0CB9 LDA #$C4
STA $034D
L0CBE LDA $034E
CMP L085C
BCS L0CCE
LDA $034F
BNE L0CCE
JMP L0C78
L0CCE LDA L084E
CMP #$02
BEQ L0CD9
LDY #$02
BNE L0CDB
L0CD9 LDY #$01
L0CDB LDA $034E
ASL
STA $034E
LDA $034F
ROL
STA $034F
BCC L0CF0
ORA #$80
STA $034F
L0CF0 DEY
BNE L0CDB
L0CF3 LDA L0803
STA $00
LDA L0804
STA $01
LDA L0805
STA $02
LDA L0806
STA $03
LDA $034D
CMP #$C4
BNE L0D54
LDY #$00
L0D10 LDA ($02),Y
AND #$83
CMP #$81
BCC L0D35
LDA ($02),Y
AND #$7F
STA ($02),Y
DEC $034E
LDA $034E
CMP #$FF
BNE L0D35
DEC $034F
LDA $034F
CMP #$FF
BNE L0D35
JMP L0D4D
L0D35 LDA $02
SEC
SBC #$08
STA $02
BCS L0D10
DEC $03
LDA $03
CMP $01
BCS L0D10
L0D46 LDA #$FF
STA $034B
SEC
RTS
L0D4D LDA #$00
STA $034C
CLC
RTS
L0D54 LDY #$00
L0D56 LDA ($02),Y
AND #$80
BNE L0D77
ORA #$80
STA ($02),Y
DEC $034E
LDA $034E
CMP #$FF
BNE L0D77
DEC $034F
LDA $034F
CMP #$FF
BNE L0D77
JMP L0D4D
L0D77 DEY
CPY #$FF
BNE L0D56
DEC $03
LDA $03
CMP $01
BCS L0D56
BCC L0D46
L0D86 LDA #$02
STA $00
LDA $16
STA $01
L0D8E LDY #$FD
LDA ($00),Y
BPL L0DA1
INY
INY
LDA ($00),Y
BPL L0DA1
DEY
LDA ($00),Y
ORA #$80
STA ($00),Y
L0DA1 INC $01
LDA $01
CMP $0D
BNE L0D8E
RTS
L0DAA LDA $0354
CMP #$D6
BEQ L0DB6
LDA #$D2
STA $0354
L0DB6 JSR L1D9F
LDA $04
AND #$F0
TAX
LDA $16
STA $01
CLC
ADC $0378
STA $0D
LDA #$00
STA $00
LDA $0354
CMP #$D6
BEQ L0DD6
JSR L18E0
L0DD6 LDA L0866
BEQ L0E00
LDY #$00
L0DDD LDA $C08C,X
BPL L0DDD
STA ($00),Y
INY
BNE L0DDD
INC $01
LDA $01
CMP $0D
BNE L0DDD
LDA $C088,X
JMP L0EED
ds \
L0E00 LDY #$00
L0E02 BIT $00
LDA $C08C,X
BMI L0E53
LDA $C08C,X
BMI L0E53
L0E0E LDA $C08C,X
BMI L0E53
LDA $C08C,X
BMI L0E42
LDA $C08C,X
BMI L0E42
LDA $C08C,X
BMI L0E42
LDA $C08C,X
BMI L0E42
L0E27 NOP
NOP
LDA $C08C,X
BMI L0E53
L0E2E LDA $C08C,X
BMI L0E53
LDA $C08C,X
BMI L0E42
LDA $C08C,X
BMI L0E42
LDA $C08C,X
BMI L0E42
L0E42 AND #$7F
STA ($00),Y
INY
BNE L0E27
INC $01
LDA $01
CMP $0D
BCC L0E2E
BCS L0E61
L0E53 STA ($00),Y
INY
BNE L0E02
NOP
INC $01
LDA $01
CMP $0D
BCC L0E0E
L0E61 LDA $C088,X
JSR L0D86
JSR L1242
JMP L0EED
L0E6D HEX FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
HEX FFFF000000000000FF00000000000000
HEX FFFFFFFF00000000FF00000000000000
HEX FFFF000000000000FF00000000000000
HEX FFFFFFFFFFFFFFFFFF00000000000000
HEX FFFF000000000000FF00000000000000
HEX FFFFFFFF00000000FF00000000000000
HEX FFFF000000000000FF00000000000000
L0EED LDA $0354
CMP #$D6
BEQ L0EFC
LDA #$C1
STA $0354
JSR L1C63
L0EFC LDY #$00
STY $00
LDA $16
STA $01
L0F04 LDA ($00),Y
AND #$7F
BNE L0F0F
LDA L0817
STA ($00),Y
L0F0F INY
BNE L0F04
INC $01
LDA $01
CMP $0D
BNE L0F04
JMP L0F1D
L0F1D LDA L0819
BNE L0F25
JMP L0FC2
L0F25 LDY #$00
STY $00
LDA $16
STA $01
L0F2D LDX #$0B
L0F2F LDA L081E,X
BEQ L0F3D
LDA ($00),Y
ORA #$80
CMP L081E,X
BNE L0F4F
L0F3D INY
BNE L0F48
INC $01
LDA $01
CMP $0D
BCS L0FBD
L0F48 INX
CPX #$0E
BEQ L0F60
BNE L0F2F
L0F4F CPX #$0B
BNE L0F2D
INY
BNE L0F2D
INC $01
LDA $01
CMP $0D
BCS L0FBD
BCC L0F2D
L0F60 INY
BNE L0F6B
INC $01
LDA $01
CMP $0D
BCS L0FBD
L0F6B LDA L0817
STA ($00),Y
INY
BNE L0F7B
INC $01
LDA $01
CMP $0D
BCS L0FBD
L0F7B LDA ($00),Y
ORA #$80
CMP L081E
BNE L0F99
INY
BNE L0F89
INC $01
L0F89 LDA ($00),Y
ORA #$80
CMP L081F
BEQ L0F2D
DEY
CPY #$FF
BNE L0F99
DEC $01
L0F99 LDA ($00),Y
ORA #$80
CMP L082C
BNE L0F6B
INY
BNE L0FA7
INC $01
L0FA7 LDA ($00),Y
ORA #$80
CMP L082D
BNE L0FB3
JMP L0F2D
L0FB3 DEY
CPY #$FF
BNE L0F6B
DEC $01
JMP L0F6B
L0FBD JMP L0FC2
L0FC0 PLA
RTS
L0FC2 LDA L0818
BNE L0FC8
RTS
L0FC8 LDY #$00
STY $00
LDA $16
STA $01
L0FD0 LDA L0842
STA $036E
LDA #$00
STA $17
STA $13
STY $15
LDA $01
STA $14
L0FE2 LDA ($00),Y
PHA
INY
BNE L0FF2
INC $01
LDA $01
CMP $0D
BEQ L0FC0
BCS L0FC0
L0FF2 PLA
BMI L1000
L0FF5 INC $17
BNE L0FE2
LDA #$FF
STA $13
JMP L0FE2
L1000 LDA $17
SEC
SBC #$03
BCC L1045
LDA ($00),Y
INY
PHA
BNE L1015
INC $01
LDA $01
CMP $0D
BEQ L0FC0
L1015 DEC $036E
PLA
BPL L101E
JMP L1033
L101E SEC
LDA L0842
SBC $036E
CLC
ADC $17
STA $17
LDA L0842
STA $036E
JMP L0FF5
L1033 LDA $036E
BNE L1000
LDX L0842
L103B DEY
CPY #$FF
BNE L1042
DEC $01
L1042 DEX
BNE L103B
L1045 LDA $13
BEQ L104C
JMP L0FD0
L104C LDA $17
CMP L0816
BCS L1056
JMP L0FD0
L1056 LDA $15
STA $00
LDA $01
PHA
LDA $14
STA $01
TYA
PHA
LDY #$00
L1065 LDA ($00),Y
BMI L1071
LDA L0817
STA ($00),Y
JMP L107B
L1071 LDA L0843
BEQ L107B
LDA L0817
STA ($00),Y
L107B INY
BNE L1081
JMP L0DAA
L1081 CPY $17
BCC L1065
PLA
TAY
PLA
STA $01
LDA #$00
STA $00
JMP L0FD0
L1091 JSR L11A2
LDA #$00
STA KVERSION
LDA #$C0
STA $0355
LDA $08
ASL
ASL
PHA
TAX
LDA L0803,X
STA $0E
STA $00
LDA L0804,X
STA $0F
STA $01
LDA $0E
SEC
SBC #$7F
BCS L10BB
DEC $01
L10BB STA $00
LDA L081D
BEQ L10DB
LDA #$00
TAY
STA ($00),Y
LDA #$34
LDY $08
L10CB DEY
BMI L10D5
CLC
ADC $0378
JMP L10CB
L10D5 STA $01
LDA #$00
STA $00
L10DB PLA
TAX
LDA L0805,X
STA $14
STA $02
LDA L0806,X
STA $17
STA $03
LDA $03
CMP #$BF
BCC L10FC
LDA #$03
LDY $08
STA L0925,Y
LDA #$BF
STA $03
L10FC LDA #$00
TAY
STA ($02),Y
LDA L081B
BEQ L112D
LDY $08
LDA L0925,Y
BNE L112D
LDA L084C
CMP #$01
BNE L111B
LDA L081B
CMP #$02
BNE L112D
L111B LDA L081B
STA $84
LDA #$01
STA L081B
JSR L1999
LDA $84
STA L081B
L112D JSR L18E0
LDA L081D
BNE L113E
LDA $00
STA $17
LDA #$00
STA $00
RTS
L113E LDY #$00
LDA ($00),Y
ORA #$80
NOP
NOP
L1146 STA $0200,X
CMP $0200,X
CPY $00
L114E INY
BNE L1172
INC $01
LDA ($00),Y
NOP
BEQ L119A
ORA #$80
STA $0200,X
CMP $0200,X
JMP L114E
ORA #$80
STA $0200,X
CMP $0200,X
NOP
NOP
JMP L114E
NOP
NOP
L1172 LDA ($00),Y
BEQ L119A
BPL L117D
CPY $00
JMP L1146
L117D ORA #$80
BIT $00
STA $0200,X
CMP $0200,X
NOP
NOP
JMP L114E
NOP
NOP
BIT $00
STA $0200,X
CMP $0200,X
JMP L114E
RTS
L119A INY
STY $17
BNE L11A1
INC $01
L11A1 RTS
L11A2 LDA L085D
BEQ L11EB
LDA L084F
BNE L11EB
LDA #$1F
STA $14
LDY #$00
LDA $037D
AND #$F0
TAX
LDA $C08D,X
LDA $C08E,X
BMI L11EB
LDA #$FF
STA $C08F,X
CMP $C08C,X
PHA
PLA
BIT $00
L11CC PHA
PLA
L11CE LDA L0815
ORA #$80
STA $C08D,X
CMP $C08C,X
NOP
BIT $00
DEY
BNE L11CC
DEC $14
BNE L11CE
PHA
PLA
LDA $C08E,X
LDA $C08C,X
L11EB RTS
L11EC JSR L1091
LDA $0E
STA $02
STA $00
STA $17
LDA $0F
STA $03
STA $01
STA $14
LDX #$00
LDY #$00
L1203 LDA ($00),Y
BEQ L122B
BMI L1218
INX
CPX L084D
BCC L121A
INC $00
BNE L1203
INC $01
JMP L1203
L1218 LDX #$00
L121A STA ($02),Y
INC $02
BNE L1222
INC $03
L1222 INC $00
BNE L1203
INC $01
JMP L1203
L122B LDA #$00
STA ($02),Y
LDA $17
STA $00
LDA $14
STA $01
LDA $03
STA L0806
LDA $02
STA L0805
RTS
L1242 DEC $01
DEY
LDA #$80
STA $17
L1249 LDA ($00),Y
BIT $17
STA $17
BMI L1255
AND #$7F
BPL L1257
L1255 ORA #$80
L1257 STA ($00),Y
DEY
CPY #$FF
BNE L1249
DEC $01
LDX $16
DEX
CPX $01
BNE L1249
RTS
L1268 LDA L0810
STA $037C
L126E LDX $07
LDA #$00
STA L0925,X
TXA
ASL
ASL
STA $10
LDY #$00
STY $00
LDA $16
CLC
ADC #$02
STA $01
LDA L084C
CMP #$01
BNE L1294
LDA #$68
STA $0364
JMP L129C
L1294 LDA $0D
SEC
SBC #$1D
STA $0364
L129C LDA #$C8
STA $0374
LDA L0861
BNE L12B7
LDA L0865
CMP #$03
BEQ L12B7
CMP #$01
BEQ L12B4
JMP L1745
L12B4 JMP L1356
L12B7 LDX #$00
L12B9 STY $15
LDA $01
STA $14
L12BF LDA L081E,X
BEQ L12CD
LDA ($00),Y
ORA #$80
CMP L081E,X
BNE L12E5
L12CD INX
CPX L081A
BCC L12DA
JSR L14B5
BCC L1318
BCS L129C
L12DA INY
BNE L12BF
JSR L14A8
BCS L12F3
JMP L12BF
L12E5 TXA
BNE L12B7
INY
BNE L12B9
JSR L14A8
BCS L12F3
JMP L12B9
L12F3 LDA L084F
BEQ L1356
DEC $037C
BMI L1303
JSR L0DAA
JMP L126E
L1303 LDA $16
STA $14
LDA #$00
STA $15
LDY $07
LDA #$02
STA L0925,Y
JSR L158C
JMP L15EF
L1318 LDA L0861
BEQ L1342
LDA $15
CLC
ADC L0862
STA $00
LDA $14
ADC L0863
STA $01
LDA L0864
BEQ L1348
LDX #$00
LDY L081A
L1336 DEY
BMI L1342
LDA ($00),Y
STA L081E,X
INX
JMP L1336
L1342 JSR L158C
JMP L15EF
L1348 LDY L081A
L134B DEY
BMI L1342
LDA ($00),Y
STA L081E,Y
JMP L134B
L1356 LDA #$D3
STA $0374
LDY $07
LDA #$02
STA L0925,Y
LDY #$00
STY $00
STY $0362
STY $0360
LDA $16
CLC
ADC #$02
STA $01
STA $0361
L1376 LDA #$AA
STA $15
LDX #$00
L137C LDA ($00),Y
PHA
INY
BNE L138B
JSR L14A8
BCC L138B
PLA
JMP L1470
L138B PLA
AND #$80
BNE L137C
L1390 INX
BNE L1397
LDA #$FF
STA $15
L1397 LDA ($00),Y
PHA
INY
BNE L13A6
JSR L14A8
BCC L13A6
PLA
JMP L1470
L13A6 PLA
AND #$80
BEQ L1390
LDA L0853
BNE L13BA
LDA $15
CMP #$FF
BNE L13BA
TAX
JMP L140E
L13BA LDA $15
CMP #$FF
BEQ L1376
CPX L0816
BCS L13C8
JMP L1376
L13C8 CPX $0362
BCC L1376
BEQ L1376
CPX #$01
BNE L140E
TXA
PHA
TYA
PHA
LDA $01
PHA
LDX #$20
LDA #$00
STA $1D
L13E0 LDA ($00),Y
AND #$80
BNE L13E8
INC $1D
L13E8 DEX
BEQ L13F3
INY
BNE L13E0
JSR L14A8
BCC L13E0
L13F3 PLA
STA $01
PLA
TAY
PLA
LDX $1D
BEQ L1404
CPX #$10
BCS L140D
JMP L1443
L1404 LDX $0362
BEQ L1447
TAX
JMP L1376
L140D TAX
L140E TXA
PHA
TYA
PHA
LDA $01
PHA
LDA #$08
STA $1D
L1419 LDA ($00),Y
AND #$80
BEQ L1435
LDA ($00),Y
AND #$7F
TAX
LDA L0E6D,X
BNE L1435
DEC $1D
BEQ L1435
INY
BNE L1419
JSR L14A8
BCC L1419
L1435 PLA
STA $01
PLA
TAY
PLA
LDX $1D
BEQ L1443
TAX
JMP L1376
L1443 TAX
STX $0362
L1447 TYA
BNE L144C
DEC $01
L144C DEY
STY $0360
LDA $01
STA $0361
LDY $07
LDA #$00
STA L0925,Y
LDA L084C
CMP #$04
BEQ L1470
LDA L085F
BNE L1470
JSR L14A8
BCS L1470
JMP L1376
L1470 LDY $07
LDA L0925,Y
BEQ L147A
JMP L1742
L147A JSR L14B5
BCC L1494
LDA $037C
BMI L148D
LDA L0816
STA $0362
JMP L1376
L148D LDY $07
LDA #$02
STA L0925,Y
L1494 LDA $0360
STA $15
STA $00
LDA $0361
STA $14
STA $01
JSR L158C
JMP L15EF
L14A8 INC $01
LDA $01
CMP $0364
BEQ L14B3
BCC L14B4
L14B3 SEC
L14B4 RTS
L14B5 LDA L085F
BNE L14BC
CLC
RTS
L14BC LDA $0374
CMP #$C8
BEQ L14E1
LDA $0360
CLC
ADC #$0F
STA $00
LDA $0361
ADC #$00
STA $01
LDA $0360
CLC
ADC L0856
STA $02
LDA $0361
JMP L14F8
L14E1 LDA $15
CLC
ADC #$0F
STA $00
LDA $14
ADC #$00
STA $01
LDA $15
CLC
ADC L0856
STA $02
LDA $14
L14F8 ADC L0855
STA $03
LDA $02
SEC
SBC #$2F
STA $02
BCS L1508
DEC $03
L1508 LDY #$00
L150A LDA ($00),Y
AND #$F0
ORA #$80
CMP #$80
BEQ L1553
CMP #$90
BEQ L1553
CMP #$C0
BEQ L1553
LDA L0841
BNE L152B
LDA ($00),Y
AND #$7F
TAX
LDA L0E6D,X
BNE L1553
L152B LDA $01
CMP $03
BEQ L1542
INC $00
BNE L150A
INC $01
LDA $01
CMP $03
BCC L150A
BEQ L1544
JMP L154A
L1542 INC $00
L1544 LDA $00
CMP $02
BCC L150A
L154A LDY $07
LDA #$00
STA L0925,Y
CLC
RTS
L1553 DEC $037C
LDA $0374
CMP #$C8
BNE L1571
LDA $15
CLC
ADC #$03
TAY
BCC L1567
INC $14
L1567 LDA $14
STA $01
LDA #$00
STA $00
SEC
RTS
L1571 LDA #$00
STA $00
LDA $0361
CLC
ADC #$01
STA $01
CMP $0364
BCC L1587
PLA
PLA
JMP L148D
L1587 LDY $0360
SEC
RTS
L158C LDA fgCOMMAND
BEQ L15D9
LDA $16
STA $03
LDA $15
STA $00
LDA $14
STA $01
DEC $00
LDA $00
CMP #$FF
BNE L15A7
DEC $01
L15A7 LDY #$00
L15A9 LDA ($00),Y
BMI L15BA
TAX
LDA L0E6D,X
BEQ L15C6
LDA #$7F
STA ($00),Y
JMP L15C6
L15BA AND #$7F
TAX
LDA L0E6D,X
BEQ L15C6
LDA #$FF
STA ($00),Y
L15C6 DEC $00
LDA $00
CMP #$FF
BNE L15A9
DEC $01
LDA $01
CMP $03
BCC L15D9
JMP L15A9
L15D9 LDA $15
STA $00
STA $09
STA $0349
LDA $14
STA $01
STA $0A
STA $034A
JSR L16EF
RTS
L15EF LDA L0854
BEQ L160D
LDA $00
CLC
ADC L0856
STA $15
LDA $01
ADC L0855
CMP #$C0
BCS L166B
STA $14
JSR L16EF
JMP L1729
L160D LDA $01
CLC
ADC L0813
STA $03
CMP $0D
BEQ L1647
BCS L1647
LDY #$00
LDX #$00
STY $02
SEC
LDA $00
SBC $033E
STA $00
BCS L162D
DEC $01
L162D LDA ($00),Y
EOR ($02),Y
AND #$7F
BEQ L1675
INC $02
BNE L166E
INC $03
LDA $03
CMP #$C0
BCS L1647
CMP $0D
BEQ L1647
BCC L166E
L1647 DEC $037C
BMI L166B
LDA L0810
SEC
SBC #$01
CMP $037C
BNE L1665
LDA L0860
SEC
SBC #$04
STA L0860
LDA #$00
STA $033E
L1665 JSR L0DAA
JMP L126E
L166B JMP L1742
L166E LDY #$00
LDX #$00
JMP L162D
L1675 INX
INY
CPX L0860
BCC L162D
CLC
LDA $033E
ADC $02
STA $02
BCC L1688
INC $03
L1688 LDA $07
CLC
ROL
TAY
LDA $02
SEC
SBC $09
STA $0341,Y
LDA $03
SBC $0A
STA $0342,Y
LDY #$00
LDA #$FF
STA $0376
L16A3 LDA L084A
STA $036E
INC $0376
L16AC DEC $02
LDA $02
CMP #$FF
BNE L16B6
DEC $03
L16B6 LDA ($02),Y
BPL L16A3
AND #$7F
TAX
LDA L0E6D,X
BNE L16A3
DEC $036E
BNE L16AC
LDA L084A
CLC
ADC $02
STA $02
BCC L16D3
INC $03
L16D3 LDY $0376
BEQ L16E1
LDA $02
CLC
ADC #$03
BCC L16E1
INC $03
L16E1 STA $02
STA $15
LDA $03
STA $14
JSR L16EF
JMP L1705
L16EF LDX $10
LDA $15
STA L0803,X
STA $17
INX
LDA $14
STA L0803,X
STA $0375
INX
STX $10
RTS
L1705 DEX
LDA L0803,X
SEC
SBC $0A
CMP L0812
BCC L1729
DEC $10
DEC $10
LDY $07
LDA L0925,Y
BNE L1721
LDA #$03
STA L0925,Y
L1721 LDA $037C
BMI L1729
JMP L1647
L1729 JSR L1873
LDA fgCOMMAND
BNE L1733
CLC
RTS
L1733 LDA L081B
JSR L193C
CLC
LDA $0D
STA $16
RTS
JMP L1647
L1742 JSR L0DAA
L1745 LDA $07
ASL
ASL
STA $10
LDA #$C7
STA $0374
LDA $16
STA $01
STA $03
LDY #$00
STY $00
STY $02
STY $0362
L175F LDA ($00),Y
AND #$7F
TAX
INY
BNE L1770
INC $01
LDA $01
CMP $0364
BEQ L17CB
L1770 LDA L0E6D,X
BEQ L175F
STY $09
LDA $01
STA $0A
L177B LDA #$80
STA $13
L177F DEC $13
BEQ L17A2
LDA ($00),Y
AND #$7F
TAX
INY
BNE L1794
INC $01
LDA $01
CMP $0364
BEQ L17CB
L1794 LDA L0E6D,X
BEQ L177F
STY $15
LDA $01
STA $14
JMP L177B
L17A2 LDA $15
SEC
SBC $09
STA $1D
LDA $14
SBC $0A
STA $19
BNE L17D3
LDA $1D
CMP $0362
BCS L17BB
JMP L175F
L17BB LDA $1D
STA $0362
LDA $15
STA $02
LDA $14
STA $03
JMP L175F
L17CB LDA $02
STA $15
LDA $03
STA $14
L17D3 JSR L158C
LDA $00
CLC
ADC #$02
STA $00
BCC L17E1
INC $01
L17E1 LDA $01
CLC
ADC L0813
STA $03
CMP $0D
BEQ L1815
BCS L1815
LDA #$00
STA $02
L17F3 LDY #$00
LDX #$00
L17F7 LDA ($00),Y
EOR ($02),Y
AND #$7F
BEQ L180E
INC $02
BNE L17F3
INC $03
LDA $03
CMP $0D
BEQ L1815
JMP L17F3
L180E INX
INY
CPX L0860
BCC L17F7
L1815 SEC
LDA $02
SBC $00
STA $02
LDA $03
SBC $01
STA $03
SEC
LDA $02
SBC $1D
STA $02
LDA $03
SBC $19
STA $03
CMP L0812
BCC L183C
LDA #$18
STA $03
LDA #$86
STA $02
L183C LDA $07
ASL
TAY
LDA $02
STA $0341,Y
LDA $03
STA $0342,Y
CLC
LDA $15
ADC $02
STA $02
STA $15
LDA $14
ADC $03
STA $03
STA $14
LDA #$20
CLC
ADC $15
STA $15
BCC L1866
INC $14
L1866 JSR L16EF
LDY $07
LDA #$00
STA L0925,Y
JMP L1729
L1873 LDA L0844
BEQ L18DE
LDA $07
ASL
ASL
TAY
LDA L0803,Y
STA $00
INY
LDA L0803,Y
STA $01
CLC
ADC #$19
CMP #$BF
BCC L1891
LDA #$BF
L1891 STA $03
LDY #$00
LDX #$00
L1897 LDA L0845,X
BEQ L18A2
EOR ($00),Y
AND #$7F
BNE L18D9
L18A2 INX
CPX #$05
BEQ L18B6
L18A7 INY
BNE L1897
INC $01
LDA $01
CMP $03
BEQ L18DE
BCS L18DE
BCC L1897
L18B6 DEX
L18B7 LDA L0845,X
BEQ L18C0
BMI L18C0
STA ($00),Y
L18C0 DEY
CPY #$FF
BNE L18C7
DEC $01
L18C7 DEX
BPL L18B7
TYA
CLC
ADC #$06
BCC L18D2
INC $01
L18D2 TAY
LDA $01
CMP $03
BCS L18DE
L18D9 LDX #$00
JMP L18A7
L18DE CLC
RTS
L18E0 LDA L081D
BEQ L1929
LDA $05
CMP L081C
BEQ L1929
STA $17
LDA $0354
PHA
LDA #$D3
STA $0354
JSR L1C63
PLA
STA $0354
LDA L081C
STA $06
JSR L1CC1
LDA #$9F
JSR WAIT
L190B LDY #$00
L190D LDA L0832,Y
BEQ L192E
L1912 LDA $C08C,X
BPL L1912
CMP L0832,Y
BNE L190B
INY
CPY L0840
BNE L190D
L1922 LDA $17
STA $06
JSR L1CC1
L1929 JSR L1C63
CLC
RTS
L192E LDA $C08C,X
BPL L192E
INY
CPY L0840
BMI L190D
JMP L1922
L193C LDA #$00
STA $0359
LDA KBD
CMP #$9B ; escape
BNE L1958
LDA KBDSTROBE
PLA
PLA
LDA #$00
STA $0357
JSR L2A23
JMP L2874
L1958 LDX $10
DEX
LDA L0803,X
STA $17
DEX
LDA L0803,X
STA $14
DEX
LDA L0803,X
STA $0F
STA $01
DEX
LDA L0803,X
STA $0E
STA $00
L1976 LDA L081B
BNE L197D
CLC
RTS
L197D LDA fgCOMMAND
BNE L1999
LDA $0359
BNE L1999
L1987 LDA $16
STA $0F
LDA $0D
STA $17
DEC $17
LDA #$00
STA $0E
LDA #$FF
STA $14
L1999 LDA #$04
STA $22
LDA #$0F
STA $23
JSR HOME
LDY $07
LDA L0925,Y
CMP #$02
BCC L19B0
JMP L1AEF
L19B0 LDY #$00
JSR L1B73
TYA
PHA
LDA #$00
STA $033C
STA $0371
LDA $05
CLC
ROR
BCC L19CA
LDY #$25
STY $033C
L19CA CLC
ROR
BCC L19D3
LDY #$50
STY $0371
L19D3 JSR PRBYTE
LDA $033C
CLC
ADC $0371
BEQ L19E9
PHA
LDA #$AE
JSR COUT1
PLA
JSR PRBYTE
L19E9 PLA
TAY
JSR L1B73
TYA
PHA
LDX $0E
LDA $0F
JSR PRNTAX
PLA
TAY
JSR L1B73
SEC
LDA $14
SBC $0E
STA $0375
LDA $17
SBC $0F
JSR PRBYTE
LDA $0375
JSR PRBYTE
LDA $0359
BEQ L1A19
JMP L2AC3
L1A19 LDA fgCOMMAND
BNE L1A22
JSR L2AC3
RTS
L1A22 JSR CROUT
JSR CROUT
LDA L081B
CMP #$02
BNE L1A32
JMP L1AD1
L1A32 LDA #$07
STA $036F
LDX #$07
JSR PRBL2
LDA $0F
STA $1F
LDA $0E
SEC
SBC #$08
BCS L1A49
DEC $1F
L1A49 STA $1E
LDY #$00
L1A4D LDX #$08
L1A4F LDA ($1E),Y
STY $15
BMI L1A5C
PHA
JSR SETINV
PLA
ORA #$80
L1A5C JSR PRBYTE
JSR SETNORM
LDA #$A0
JSR COUT1
LDY $15
INY
DEX
BNE L1A4F
JSR CROUT
DEC $036F
BEQ L1A7D
LDX #$07
JSR PRBL2
JMP L1A4D
L1A7D LDY #$00
L1A7F LDA L1B92,Y
INY
CMP #$A6
BEQ L1A8D
JSR COUT1
JMP L1A7F
L1A8D LDA #$21
STA $24
LDY #$00
LDA $0374
CMP #$C8
BEQ L1AA5
CMP #$C7
BNE L1AA3
LDY #$0C
JMP L1AA5
L1AA3 LDY #$07
L1AA5 LDA L1B82,Y
INY
CMP #$A6
BEQ L1AB3
JSR COUT1
JMP L1AA5
L1AB3 LDA L0854
BNE L1ACA
LDA #$0A
STA $24
LDA $07
CLC
ROL
TAY
LDA $0342,Y
LDX $0341,Y
JSR PRNTAX
L1ACA LDA L081B
CMP #$02
BNE L1AEE
L1AD1 JSR L2AC3
LDX $10
DEX
LDA $17
STA L0803,X
DEX
LDA $14
STA L0803,X
DEX
LDA $0F
STA L0803,X
DEX
LDA $0E
STA L0803,X
L1AEE RTS
L1AEF LDY #$00
L1AF1 LDA L1BB6,Y
INY
CMP #$A6
BEQ L1AFF
JSR COUT1
JMP L1AF1
L1AFF LDA fgCOMMAND
BNE L1B16
LDY #$14
L1B06 LDA #$00
JSR WAIT
DEY
BNE L1B06
LDA #$00
STA L0925
JMP L1987
L1B16 LDA L081B
CMP #$02
BNE L1AEE
JSR CROUT
LDY #$00
L1B22 LDA L1BD1,Y
BEQ L1B2E
INY
JSR COUT1
JMP L1B22
L1B2E JSR RDKEY
CMP #$9B
BNE L1B3A
PLA
PLA
JMP (SOFTEV)
L1B3A CMP #$D2
BNE L1B46
PLA
PLA
JSR L0DAA
JMP L1268
L1B46 CMP #$C5 ; E
BNE L1B4C
BEQ L1B5A
L1B4C CMP #$CE ; N
BNE L1B70
JSR L0DAA
LDY $07
LDA #$02
STA L0925,Y
L1B5A LDA $16
STA $0F
LDA #$00
STA $0E
LDA $0D
SEC
SBC #$01
STA $17
LDA #$FF
STA $14
JMP L1AD1
L1B70 JMP L1AEE
L1B73 LDA L1C46,Y
INY
CMP #$A6
BEQ L1B81
JSR COUT1
JMP L1B73
L1B81 RTS
L1B82 inv 'HEADER'
ASC "&"
inv 'SYNC'
ASC "&"
inv 'GAP'
ASC "&"
L1B92 ASC 8D" "
inv 'SOURCE:'
ASC " "
inv 'OBJECT:'
ASC " &"
L1BB6 ASC 8D
ASC " UNABLE TO ANALYZE TRACK &"
L1BD1 ASC 8D
ASC " PRESS:"8D8D
ASC " "12
ASC " TO RETRY"8D
ASC " "05
ASC " TO EDIT AS IS"8D
ASC " "0E
ASC " TO RE-READ & EDIT W/O ANALYSIS"8D
ASC " "
inv 'RETURN'
ASC " TO SKIP THIS TRACK "00
L1C46 inv 'TRACK:'
ASC " &"
ASC " "
inv 'START:'
ASC " &"
ASC " "
inv 'LENGTH:'
ASC " &"
L1C63 LDA fgCOMMAND
BNE L1C69
RTS
L1C69 LDA $23
STA $0373
LDA $22
STA $0376
LDA #$12
STA $22
LDA #$18
STA $23
LDA $05
LSR
AND #$01
CLC
ADC #$15
STA $25
JSR VTAB
LDA $05
LSR
LSR
CLC
ADC #$04
STA $24
LDA $0354
CMP #$10
BCC L1CAB
CMP #$A0
BEQ L1C9F
JSR SETINV
L1C9F LDA $0354
JSR COUT1
JSR SETNORM
JMP L1CB6
L1CAB LDY $08
LDA L0925,Y
CLC
ADC #$B0
JSR COUT1
L1CB6 LDA $0376
STA $22
LDA $0373
STA $23
RTS
L1CC1 JSR L1D9F
LDA $04
AND #$F0
TAX
STX $2B
LDA $06
CMP $05
BNE L1CD4
JMP L1D48
L1CD4 LSR
STA $033D
LDA $05
AND #$01
BEQ L1CF0
LDA $05
LSR
PHA
SEC
JSR L1D3D
LDA #$FF
JSR L1D49
PLA
CLC
JSR L1D3D
L1CF0 LSR $05
LDA #$00
STA $26
L1CF6 LDA $05
STA $27
SEC
SBC $033D
BEQ L1D31
BCS L1D08
EOR #$FF
INC $05
BCC L1D0C
L1D08 ADC #$FE
DEC $05
L1D0C CMP $26
BCC L1D12
LDA $26
L1D12 CMP #$0C
BCS L1D17
TAY
L1D17 SEC
JSR L1D3B
LDA L1D87,Y
JSR L1D49
LDA $27
CLC
JSR L1D3D
LDA L1D93,Y
JSR L1D49
INC $26
BNE L1CF6
L1D31 JSR L1D49
CLC
JSR L1D3B
JMP L1D5A
L1D3B LDA $05
L1D3D AND #$03
ROL
ORA $2B
TAX
LDA $C080,X
LDX $2B
L1D48 RTS
L1D49 LDX #$11
L1D4B DEX
BNE L1D4B
INC $46
BNE L1D54
INC $47
L1D54 SEC
SBC #$01
BNE L1D49
RTS
L1D5A LDA $06
STA $05
AND #$01
BEQ L1D86
LDA $06
LSR
SEC
PHA
JSR L1D3D
PLA
CLC
ADC #$01
SEC
PHA
JSR L1D3D
LDA #$FF
JSR L1D49
PLA
CLC
PHA
JSR L1D3D
PLA
SEC
SBC #$01
CLC
JSR L1D3D
L1D86 RTS
L1D87 HEX 01302824201E1D1C1C1C1C1C
L1D93 HEX 702C26221F1E1D1C1C1C1C1C
L1D9F PHP
LDA $04
CLC
ADC #$09
TAX
LDA $C080,X
LDA $04
AND #$F0
CLC
ADC #$09
TAX
LDA $C080,X
LDA $04
AND #$F0
TAX
LDA $C080,X
LDA $C082,X
LDA $C084,X
LDA $C086,X
LDY #$03
JSR L1DCC
PLP
RTS
L1DCC LDA #$00
JSR WAIT
DEY
BNE L1DCC
RTS
L1DD5 LDA $04
AND #$F0
TAX
LDA $C080,X
LDA $C082,X
LDA $C084,X
LDA $C086,X
LDA #$C0
STA $05
LDA #$00
STA $06
JSR L1CC1
RTS
L1DF2 LDA fgOUTPUT
CMP #$F0
BNE L1DFC
JMP L1F3D
L1DFC LDA #$F0
STA $36
STA fgOUTPUT
LDA #>L0900
STA SOFTEV+1
EOR #$A5
STA PWREDUP
LDA #<L0900
STA SOFTEV
LDA #$01
STA L0816
LDA #$FE
STA L0814
LDA #$FF
STA L0815
LDA #$01
STA L0841
LDA #$02
STA L084C
LDA #$45
STA $0378
LDA #$01
STA L081B
LDA #$7F
STA L0817
LDA #$00
STA L0818
LDA #$0B
STA L081A
LDA #$10
STA L0860
LDA #$01
STA L0810
LDA #$03
STA L0811
LDA #$1A
STA L0812
LDA #$01
STA L085D
LDA #$00
STA L081D
LDA #$00
STA L081C
LDA #$10
STA L084B
LDA #$0B
STA L0840
LDA #$02
STA L0842
LDA #$10
STA L0813
LDA #$01
STA L0843
LDA #$00
STA L0844
LDA #$04
STA L084A
LDA #$00
STA L0819
LDA #$0C
STA L084D
LDA #$01
STA L084E
LDA #$40
STA L0850
LDA #$00
STA $0357
LDA #$00
STA L0853
LDA #$00
STA L0854
LDA #$00
STA L085F
LDA #$08
STA L0855
LDA #$1F
STA L0856
LDA #$01
STA L0857
LDA #$00
STA L084F
LDA #$01
STA L0858
LDA #$00
STA L0859
LDA #$0B
STA L0852
LDA #$00
STA L085B
LDA #$01
STA L085C
LDA #$01
STA L0851
LDA #$00
STA L085E
LDA #$3B
STA L085A
LDA #$00
STA $033E
LDA #$07
STA L0862
LDA #$08
STA L0863
LDA #$01
STA L0864
LDA #$00
STA L0866
LDA #$00
STA L0861
LDA #$DE
STA L0845
LDA #$AA
STA L0846
LDA #$6B
STA L0847
LDA #$00
STA L0848
STA L0849
LDA #$01
STA L0865
LDY #$21
L1F2A LDA L0903,Y
STA L081E,Y
DEY
BPL L1F2A
LDA #<KEYIN
STA $38
LDA #>KEYIN
STA $37
STA $39
L1F3D LDA $0357
BEQ L1F45
JMP L1FAC
L1F45 LDA #$00
STA $0359
STA $22
LDA #$18
STA $23
LDA #$00
STA $0372
L1F55 JSR HOME
LDY #$00
L1F5A LDA L238B,Y
INY
CMP #$A6
BEQ L1F68
JSR COUT1
JMP L1F5A
L1F68 LDY #$00
L1F6A LDA L2364,Y
INY
CMP #$A6
BEQ L1F78
JSR COUT1
JMP L1F6A
L1F78 JSR RDKEY
CMP #$D1
BNE L1F85
STA $0357
JMP L1FAC
L1F85 CMP #$C3 ; Copy
BEQ L1FA3
CMP #$8D ; Return
BEQ L1FA3
CMP #$C5 ; Edit
BNE L1F55
LDA #$00
STA fgCOMMAND
LDA #$01
STA L081B
LDA #$11
STA $037D
JMP L1FA8
L1FA3 LDA #$01
STA fgCOMMAND
L1FA8 LDA #$04
STA $22
L1FAC LDA #$16
STA $82
LDA $0357
BEQ L1FBF
CMP #$D1 ; Q
BNE L1FBC
JMP L217B
L1FBC JMP L21CF
L1FBF LDA #$04
STA $22
LDA #$18
STA $23
JSR HOME
LDX #$00
LDA SLOT16
AND #$F0
STA $17
CLC
ROR
ROR
ROR
ROR
ORA #$B0
STA $1C
LDA #$B1
STA $1A
JSR L2301
CMP #$B3
BCC L1FEF
LDA #$87
JSR COUT1
JMP L1FAC
L1FEF AND #$0F
CLC
ADC $17
STA $037E
LDA fgCOMMAND
BEQ L2017
LDA #$B2
STA $1A
JSR L2301
CMP #$B3
BCC L200F
LDA #$87
JSR COUT1
JMP L1FAC
L200F AND #$0F
CLC
ADC $17
STA $037D
L2017 LDX #$00
STX $0371
L201C LDA L2444,X
INX
CMP #$A6
BEQ L202A
JSR COUT1
JMP L201C
L202A LDA #$21
STA $0376
LDA #$47
STA $035D
LDA #$00
JSR L2719
LDA $19
CLC
ROL
ORA $0371
ROL
ORA $033C
STA $037B
LDX #$00
L2049 LDA L2468,X
INX
CMP #$A6
BEQ L2057
JSR COUT1
JMP L2049
L2057 LDA #$23
STA $035D
LDA #$22
JSR L2719
LDA $19
CLC
ROL
ORA $0371
ROL
ORA $033C
STA $11
LDA $11
CMP $037B
BCS L2078
JMP L1FAC
L2078 LDX #$00
L207A LDA L2614+$37,X
INX
CMP #$A6
BEQ L2088
JSR COUT1
JMP L207A
L2088 LDA $037B
CMP $11
BNE L20A7
LDA #$01
STA $037A
STA $19
LDA #$00
STA $0371
STA $033C
JSR CROUT
JSR L2818
JMP L20C6
L20A7 LDA #$23
STA $035D
LDA #$01
JSR L2719
LDA $19
CLC
ROL
ORA $0371
ROL
ORA $033C
STA $037A
CMP #$01
BNE L20C6
STA L084F
L20C6 LDX #$00
L20C8 LDA L248B,X
INX
CMP #$A6
BEQ L20D6
JSR COUT1
JMP L20C8
L20D6 LDA #$CE
STA $1A
JSR L230F
CMP #$CE
BEQ L20EE
LDA #$01
STA L081D
LDA #$03
STA L0865
JMP L20F3
L20EE LDA #$00
STA L081D
L20F3 LDA fgCOMMAND
BEQ L213C
LDX #$00
L20FA LDA L24AB,X
INX
CMP #$A6
BEQ L2108
JSR COUT1
JMP L20FA
L2108 LDA #$CE
STA $1A
JSR L230F
CMP #$CE
BEQ L2128
LDA #$01
STA L085B
STA L084C
LDA #$8B
STA $0378
LDA #$10
STA L0811
JMP L213C
L2128 LDA #$00
STA L085B
LDA #$02
STA L084C
LDA #$45
STA $0378
LDA #$03
STA L0811
L213C LDA #$FF
STA $035D
LDA #$10
STA $22
LDA #$18
STA $23
JSR HOME
LDX #$00
L214E LDA L266E,X
INX
CMP #$A6
BEQ L215C
JSR COUT1
JMP L214E
L215C LDA #$87
JSR COUT1
LDA KBDSTROBE
L2164 LDA KBD
BPL L2164
PHA
LDA #$00
STA KBDSTROBE
PLA
CMP #$9B ; escape
BNE L2177
JMP L1DF2
L2177 CMP #$D1 ; Q
BNE L21C4
L217B LDA #$04
STA $22
JSR CROUT
JSR HOME
LDY #$00
STY $0357
L218A LDA L2566,Y
INY
CMP #$A6
BEQ L2198
JSR COUT1
JMP L218A
L2198 JSR RDKEY
CMP #$A0 ; space
BNE L21A2
JMP L0900
L21A2 CMP #$8D ; return
BEQ L21AD
CMP #$CD ; M
BNE L2198
JMP MONZ
L21AD LDA #$00
STA fgOUTPUT
LDA SLOT16
LSR
LSR
LSR
LSR
ORA #$C0
STA $01
LDA #$00
STA $00
JMP ($0000)
L21C4 CMP #$8D ; return
BNE L21CB
JMP L2272
L21CB CMP #$AF ; /
BNE L215C
L21CF LDA #$11
STA $22
LDA #$18
STA $23
L21D7 JSR HOME
LDY #$00
L21DC LDA L22A4,Y
INY
CMP #$A6
BEQ L21EA
JSR COUT1
JMP L21DC
L21EA STY $09
LDA #$1D
STA $0376
LDA #$1D
STA $82
LDA #$FF
STA $0372
JSR L2719
LDA $19
CMP #$FF
BNE L220E
LDA fgCOMMAND
BEQ L220B
JMP L213C
L220B JMP L2272
L220E CLC
ADC #$10
STA $00
LDA #$08
STA $01
L2217 LDY $09
L2219 LDA L22A4,Y
INY
CMP #$A6
BEQ L2227
JSR COUT1
JMP L2219
L2227 LDY #$00
LDA ($00),Y
JSR PRBYTE
LDY #$00
LDA ($00),Y
JSR L2719
LDA $00
CMP #$4C
BNE L2257
LDA $19
BEQ L2243
CMP #$03
BCC L2257
L2243 LDA #$87
JSR COUT1
JSR COUT1
JSR COUT1
JSR UP
JSR CLREOL
JMP L2217
L2257 LDA $19
LDY #$00
STA ($00),Y
JSR CROUT
LDA L084C
CMP #$01
BNE L226C
LDA #$8B
STA $0378
L226C JMP L21D7
JMP L213C
L2272 LDA #$11
STA $22
JSR HOME
LDA fgCOMMAND
BEQ L228E
LDX #$00
L2280 LDA L24CB,X
INX
CMP #$A6
BEQ L229E
JSR COUT1
JMP L2280
L228E LDX #$00
L2290 LDA L25D6,X
INX
CMP #$A5
BEQ L229E
JSR COUT1
JMP L2290
L229E LDA #$00
STA $0357
RTS
L22A4 ASC 8D
ASC " - PARAMETER CHANGE -"8D8D
ASC " CHANGE WHAT PARAMETER: &"
ASC " TO WHAT VALUE: &"
L2301 LDA L2403,X
INX
CMP #$A6
BEQ L2313
JSR COUT1
JMP L2301
L230F LDA #$0B
STA $22
L2313 LDA $1A
AND #$3F
JSR COUT1
LDA #$A0
JSR COUT1
JSR COUT1
JSR COUT1
JSR RDKEY
CMP #$9B
BNE L2331
L232C PLA
PLA
JMP L1DF2
L2331 CMP #$8D
BNE L233A
LDA $1A
JMP L234E
L233A CMP #$D1 ; Q
BEQ L235E
CMP #$D9 ; Y
BEQ L234E
CMP #$CE ; N
BEQ L234E
CMP #$B8
BPL L232C
CMP #$B1
BMI L232C
L234E PHA
LDY #$16
STY $24
JSR COUT1
JSR CLREOL
JSR CROUT
PLA
RTS
L235E PHA
JSR CROUT
PLA
RTS
L2364 ASC " COPY OR EDIT (C OR E) "
inv 'DEFAULT'
ASC '='
inv 'COPY'
ASC " &"
L238B ASC " COPY ][ PLUS BIT COPY PROGRAM 4.4C BD"8D
ASC "(C) 1982-4 CENTRAL POINT SOFTWARE, INC."8D
ASC "----------------------------------------"8D
ASC "&"
L2403 ASC " ORIGINAL DRIVE: "
inv 'DEFAULT'
ASC '='
ASC "&"
ASC " DUPLICATE DRIVE: "
inv 'DEFAULT'
ASC '='
ASC "&"
L2444 ASC 8D
ASC " ENTER START TRACK: "
inv 'DEFAULT'
ASC '=00'
ASC " &"
L2468 ASC " ENTER END TRACK: "
inv 'DEFAULT'
ASC '=22'
ASC " &"
L248B ASC 8D
ASC " SYNCHRONIZE TRACKS? "
inv 'DEFAULT'
ASC '='
ASC "&"
L24AB ASC 8D
ASC " KEEP TRACK LENGTH? "
inv 'DEFAULT'
ASC '='
ASC "&"
L24CB ASC " COPY STATUS"8D
ASC "HEX 000000000000000011111111111111112222"
ASC "TRK 0123456789ABCDEF0123456789ABCDEF0123"
ASC "----------------------------------------"
ASC "ERR"8D
ASC "+.5&"
L2566 ASC 8D8D
ASC " INSERT COPY ][ PLUS DISKETTE"8D8D
ASC " AND PRESS "
inv 'RETURN'
ASC " FOR MAIN MENU"8D8D8D8D
ASC " PRESS "
inv 'SPACE'
ASC " TO RE-ENTER BIT COPY &"
L25D6 ASC 8D
ASC " "
inv 'A'
ASC " TO ANALYZE DATA "
inv 'ESC'
ASC " TO QUIT"8D8D
ASC " "
ASC '?'
ASC " FOR HELP SCREEN "
ASC '/'
L2614 ASC " CHANGE PARMS"8D8D
ASC " "
inv 'Q'
ASC " FOR NEXT TRACK "
inv 'SPC'
ASC " TO RE-READ%"8D
ASC " TRACK INCREMENT: "
inv 'DEFAULT'
ASC '=01'
ASC " &"
L266E ASC "----------------------------------------"8D
ASC " -- INSERT DISKETTES -- "8D8D
ASC " "
inv 'RETURN'
ASC " TO BEGIN "
inv 'Q'
ASC " TO QUIT"8D
ASC " "
inv 'ESC'
ASC " TO RESTART "
ASC '/'
ASC " TO MODIFY "8D
ASC " &"
L2719 STA $17
TXA
PHA
LDA $25
STA $0373
LDA #$00
STA $19
STA $0371
STA $033C
STA $14
L272E LDA $0376
STA $24
LDX #$00
L2735 JSR RDKEY
CMP #$9B
BNE L274A
LDA $0357
BNE L272E
PLA
PLA
PLA
JSR HOME
JMP L1DF2
L274A CMP #$8D
BEQ L2760
CMP #$88
BNE L2756
DEX
JMP L275A
L2756 STA $0200,X
INX
L275A JSR COUT1
JMP L2735
L2760 STA $0200,X
JSR COUT1
CPX #$00
BNE L276D
JMP L2865
L276D LDY #$00
STY $0371
JMP L2776
PHA
L2776 LDA $0200,Y
CMP #$AE ; .
BEQ L27A3
CMP #$B0 ; 0
BMI L27FC
CMP #$BA ; 9+1
BMI L2790
CMP #$C1 ; A
BMI L27FC
CMP #$C7 ; F+1
BPL L27FC
CLC
ADC #$09
L2790 AND #$0F
STA $19
DEX
BEQ L27E2
INY
LDA $0200,Y
CMP #$AB ; +
BEQ L27A3
CMP #$AE ; .
BNE L27CE
L27A3 INY
LDA $0200,Y
CMP #$B0 ; 0
BEQ L27C9
CMP #$B5 ; 5
BCC L27C2
BEQ L27BD
CMP #$B7 ; 7
BNE L27C9
INC $0371
INC $033C
BNE L27C9
L27BD INC $0371
BNE L27C9
L27C2 CMP #$B2 ; 2
BNE L27C9
INC $033C
L27C9 DEY
DEY
JMP L27E2
L27CE CMP #$A0
BNE L27D5
JMP L27E2
L27D5 LDA $19
CLC
ROL
ROL
ROL
ROL
STA $14
NOP
JMP L2776
L27E2 TYA
BEQ L27F5
LDA $14
ORA $19
STA $19
CMP $035D
BEQ L27F5
BCC L27F5
JMP L27FC
L27F5 JSR L2818
PLA
TAX
INY
RTS
L27FC JSR CROUT
LDA #$87
JSR COUT1
JSR COUT1
JSR COUT1
LDA $0373
SEC
SBC #$01
STA $25
JSR CROUT
JMP L272E
L2818 TYA
PHA
LDA $82
STA $24
JSR UP
LDA $19
CMP #$10
BCS L282D
JSR PRHEX
JMP L2830
L282D JSR PRBYTE
L2830 LDA #$00
STA $17
STA $14
LDA $0371
BEQ L283F
LDA #$50
STA $17
L283F LDA $033C
BEQ L2848
LDA #$25
STA $14
L2848 LDA $17
CLC
ADC $14
BEQ L2859
PHA
LDA #$AE
JSR COUT1
PLA
JSR PRBYTE
L2859 JSR SETNORM
JSR CLREOL
JSR CROUT
PLA
TAY
RTS
L2865 PLA
TAX
LDA $17
STA $19
JSR L2818
LDA #$00
STA $0371
RTS
*----------------------------
* Entry point
L2874 LDA #<L2A0B
STA SOFTEV
LDA #>L2A0B
STA SOFTEV+1
EOR #$A5
STA PWREDUP
JSR L1DF2
LDA $037E
STA $04
JSR L1D9F
JSR L1DD5
LDA $037B
STA $06
JSR L1CC1
L2899 LDA #$00
STA $10
STA $07
LDA #$34
STA $16
LDA $037E
CMP $037D
BNE L28E6
LDA $037D
AND #$F0
TAX
LDA $C088,X
LDA $037E
AND #$F0
TAX
LDA $C088,X
LDA #$04
STA $22
LDA #$0F
STA $23
JSR HOME
LDY #$00
L28CA LDA L2A54,Y
INY
CMP #$A6
BEQ L28D8
JSR COUT1
JMP L28CA
L28D8 JSR RDKEY
CMP #$9B
BNE L28E2
JMP L2A0B
L28E2 CMP #$8D
BNE L28D8
L28E6 LDA #$00
LDY $07
STA L0925,Y
LDA KBD
CMP #$9B
BNE L28F7
JMP L2A0B
L28F7 LDA #$04
STA $033E
LDA #$10
STA L0860
JSR L0DAA
LDA fgCOMMAND
BEQ L290F
JSR L1268
JMP L2912
L290F JSR L193C
L2912 LDA #$A0
STA $0354
JSR L1C63
LDX $037A
L291D INC $06
DEX
BNE L291D
JSR L1CC1
LDA fgCOMMAND
BNE L293C
LDA $11
CMP $05
BCS L2939
LDA $037E
STA $037D
JMP L2A0B
L2939 JMP L2899
L293C INC $07
LDA $07
CMP L084C
BEQ L294E
LDA $11
CMP $05
BCC L294E
JMP L28E6
L294E LDA $037E
EOR $037D
AND #$F0
BNE L2995
LDA $037E
AND #$F0
TAX
LDA $C088,X
LDA $037E
CMP $037D
BNE L2995
LDA #$04
STA $22
LDA #$0F
STA $23
JSR HOME
LDY #$00
L2976 LDA L2A7A,Y
INY
CMP #$A6
BEQ L2984
JSR COUT1
JMP L2976
L2984 JSR RDKEY
CMP #$9B
BNE L2991
JSR HOME
JMP L1DF2
L2991 CMP #$8D
BNE L2984
L2995 LDA #$00
STA $08
STA $10
LDA $037D
STA $04
DEC $07
LDX $07
LDA #$00
CLC
L29A7 ADC $037A
DEX
BPL L29A7
STA $07
SEC
LDA $05
SBC $07
STA $06
CMP $037B
BNE L29C6
JSR L1DD5
LDA $037B
STA $06
JSR L1CC1
L29C6 LDA $037E
CMP $037D
BEQ L29D5
LDA $06
STA $05
JMP L29D8
L29D5 JSR L1CC1
L29D8 LDA KBD
CMP #$9B
BEQ L2A0B
LDA $08
STA $07
JSR L092B
LDX $037A
L29E9 INC $06
DEX
BNE L29E9
JSR L1CC1
LDA $11
CMP $05
BCC L2A0B
INC $08
LDA $08
CMP L084C
BEQ L2A03
JMP L29D8
L2A03 LDA $037E
STA $04
JMP L2899
L2A0B LDA $037E
AND #$F0
TAX
LDA $C088,X
LDA $037D
AND #$F0
TAX
LDA $C088,X
JSR L2A23
JMP L2874
L2A23 LDA #$87
JSR COUT1
LDA #$16
STA $25
JSR VTAB
LDA #$11
STA $22
LDA #$18
STA $23
LDY #$00
L2A39 LDA L2AA4,Y
INY
CMP #$A6
BEQ L2A47
JSR COUT1
JMP L2A39
L2A47 LDA #$00
STA $0363
JSR RDKEY
STA $0363
CLC
RTS
L2A54 ASC 8D8D8D
ASC " INSERT "
inv 'ORIGINAL'
ASC " DISK IN DRIVE &"
L2A7A ASC 8D8D8D8D8D8D
ASC " INSERT "
inv 'DUPLICATE'
ASC " DISK IN DRIVE &"
L2AA4 ASC 8D
ASC " "
inv 'PRESS RETURN'
ASC "... &"
L2AC3 LDA #$05
STA $22
JSR HOME
*----------------------------
* EDITOR / GOTO BEGIN TRACK
*----------------------------
doBEGINNING LDY #$00
STY $83
STY $89
LDA #$08
STA $8A
LDA $0359
BNE L2AE1
LDA $0E
STA $86
LDA $0F
STA $87
L2AE1 LDA #$00
STA $0359
JMP L2B2A
L2AE9 PHA
AND #$80
STA $18
PLA
ORA #$80
L2AF1 PHA
LSR
LSR
LSR
LSR
JSR L2AFA
PLA
L2AFA AND #$0F
ORA #$B0
CMP #$BA
BCC L2B04
ADC #$06
L2B04 STY $34
BIT $83
BMI L2B10
LDY $18
BEQ L2B19
BNE L2B1D
L2B10 STA $88
AND #$3F
ORA #$40
JMP L2B1D
L2B19 STA $88
AND #$3F
L2B1D LDY $24
STA ($28),Y
INC $24
LDY $34
LDA #$00
STA $83
RTS
L2B2A LDA #$18
STA $8C
LDA $86
STA $80
LDA $87
STA $81
LDX #$04
L2B38 LDA $80
SEC
SBC $8A
STA $80
BCS L2B43
DEC $81
L2B43 DEX
BNE L2B38
LDA $8A
SEC
SBC #$01
PHA
EOR #$FF
AND $80
TAY
PLA
AND $80
STA $82
STY $80
LDX #$06
L2B5A TXA
JSR VTABZ
LDY #$00
STY $24
LDA #$01
STA $18
LDA $81
JSR L2AF1
LDA $80
JSR L2AF1
LDA #$BA
CPX #$0A
BNE L2B78
AND #$3F
L2B78 JSR L2B04
LDA #$A0
STA $18
JSR L2B04
L2B82 LDA ($80),Y
CPX #$0A
BNE L2B94
CPY $82
BNE L2B94
PHA
LDA $24
STA $8B
PLA
DEC $83
L2B94 JSR L2AE9
LDA #$01
STA $18
LDA #$A0
JSR L2B04
INY
CPY $8A
BCC L2B82
LDA $80
CLC
ADC $8A
STA $80
BCC L2BB0
INC $81
L2BB0 CPX #$0A
BNE L2BCE
LDA #$01
STA $18
INC $24
LDA #$BC ; <
JSR L2B04
LDA #$AD ; -
JSR L2B04
LDA $87
JSR L2AF1
LDA $86
JSR L2AF1
L2BCE INX
CPX #$0F
BCS L2BFB
CPX #$07
BNE L2BF1
JSR SETINV
LDA #$1F
STA $24
LDY #$00
L2BE0 LDA L2BF4,Y
INY
CMP #$A6
BEQ L2BEE
JSR COUT1
JMP L2BE0
L2BEE JSR SETNORM
L2BF1 JMP L2B5A
L2BF4 ASC " VIEW &"
*----------------------------
* EDITOR / WAIT FOR COMMAND
*----------------------------
L2BFB jsr show44 ; new command
JSR L322D
LDY #$14
L2C00 CMP L2C2A,Y
BEQ L2C0B
DEY
BPL L2C00
JMP L2B2A
L2C0B TYA
ASL
TAX
LDA tblCOMMANDS,X
STA $00
LDA tblCOMMANDS+1,X
STA $01
LDA #$01
DEY
DEY
BMI L2C26
LDA $8A
DEY
DEY
BMI L2C26
ASL
ASL
L2C26 TAX
JMP ($0000)
L2C2A ASC "JKIMTVQBES?CFRA/P"9B8285
ASC " "
*----------------------------
* EDITOR / GOTO NEXT TRACK
*----------------------------
doNEXTTRACK JSR HOME
LDA #$00
STA $0359
LDA #$04
STA $22
JSR HOME
RTS
*----------------------------
* EDITOR / COMMANDS
*----------------------------
tblCOMMANDS DA doLEUP ; J
DA doRIDO ; K
DA doLEUP ; I
DA doRIDO ; M
DA doLEUP ; T
DA doRIDO ; V
DA doNEXTTRACK ; Q
DA doBEGINNING ; B
DA doEND ; E
DA doTOGGLESYNC ; S
DA doHELP ; ?
DA doCHANGENIBBLE ; C
DA doFIND ; F
DA doREPEATFIND ; R
DA doANALYZE ; A
DA doCHANGEPARMS ; /
DA doPRINTTRACK ; P
DA doQUITEDITOR ; ESCAPE
DA doRESETBEGIN ; CTRL-B
DA doRESETEND ; CTRL-E
DA doREREAD ; SPACE
*----------------------------
* EDITOR / PRINT TRACK
*----------------------------
doPRINTTRACK LDA KBDSTROBE
JSR HOME
LDY #$00
L2C81 LDA L2D91,Y
INY
CMP #$A6
BEQ L2C8F
JSR COUT1
JMP L2C81
L2C8F CPY #$30
BCS L2C9F
INY
LDA L0858
ORA #$B0
JSR COUT1
JMP L2C81
L2C9F JSR RDKEY
CMP #$9B
BNE L2CA9
JMP L2D7C
L2CA9 CMP #$8D
BNE L2C9F
LDA L0858
ORA #$C0
STA $37
LDA #$00
STA $36
LDA $87
STA $01
LDA $86
AND #$F0
STA $00
LDA L085A
STA $09
LDY #$00
STY $0A
LDA #$04
STA $0356
LDY #$03
JMP L2CFB
L2CD5 LDA ($00),Y
ORA #$80
JSR PRBYTE
DEC $0356
BNE L2CEB
LDA #$A0
JSR COUT
LDA #$04
STA $0356
L2CEB INY
CPY $0A
BNE L2CF2
INC $01
L2CF2 DEX
BNE L2D6A
DEC $09
BPL L2D47
LDY #$06
L2CFB JSR CROUT
LDA L0859
JSR COUT
CPY #$02
BNE L2D3F
TYA
PHA
LDY #$00
L2D0C LDA L2DDD,Y
INY
CMP #$A6
BEQ L2D1A
JSR COUT
JMP L2D0C
L2D1A LDA $05
CLC
ROR
ROR
PHP
JSR PRBYTE
PLP
BCC L2D30
LDA #$AE
JSR COUT
LDA #$B5
JSR COUT
L2D30 JSR CROUT
LDY #$28
L2D35 LDA #$AD
JSR COUT
DEY
BNE L2D35
PLA
TAY
L2D3F DEY
BNE L2CFB
LDA L085A
STA $09
L2D47 LDA KBD
CMP #$9B
BEQ L2D7C
JSR CROUT
LDA L0859
JSR COUT
TYA
CLC
ADC $00
TAX
LDA $01
ADC #$00
JSR PRNTAX
LDA #$AD
JSR COUT
LDX #$10
L2D6A LDA $01
CMP $17
BEQ L2D75
BCS L2D7C
JMP L2CD5
L2D75 LDA $14
STA $0A
JMP L2CD5
L2D7C LDA #<COUT1
STA $36
LDA #>COUT1
STA $37
LDA KBDSTROBE
LDA #$00
STA $8C
JSR HOME
JMP L2B2A
L2D91 ASC 8D8D
ASC " PRINTER CARD IN SLOT &"
ASC 8D8D8D
ASC " TURN ON PRINTER"8D8D
ASC " PRESS "
inv 'RETURN'
ASC " WHEN READY &"
L2DDD ASC "----------------------------------------"8D
ASC "NIBBLE EDITOR TRACK DUMP TRACK &"
*----------------------------
* EDITOR / RE-READ TRACK
*----------------------------
doREREAD LDA fgCOMMAND
BNE L2E3B
JSR L0DAA
LDA #$01
STA $0359
JMP L1987
L2E3B JMP L2B2A
*----------------------------
* EDITOR / ANALYZE DATA
*----------------------------
doANALYZE LDA fgCOMMAND
BNE L2E58
JSR L1268
LDA #$01
STA $0359
LDA $0349
STA $86
LDA $034A
STA $87
JMP L1958
L2E58 JMP L2B2A
*----------------------------
* EDITOR / CHANGE PARMS
*----------------------------
doCHANGEPARMS LDA fgCOMMAND
BNE L2E89
LDA #$01
STA $0357
LDA $17
STA $0360
LDA $14
STA $0361
JSR L1DF2
LDA $0360
STA $17
LDA $0361
STA $14
LDA #$05
STA $22
LDA #$10
STA $23
LDA #$00
STA $0357
L2E89 JMP L2B2A
*----------------------------
* EDITOR / SHOW 4*4
*----------------------------
show44 lda #8 ; gotoxy(31,8)
sta $25
jsr VTABZ
lda #31
sta $24
lda #"4"
jsr COUT1
lda #"*"
jsr COUT1
lda #"4"
jsr COUT1
lda #":"
jsr COUT1
ldy #0 ; print 4*4 value
lda ($86),y ; under cursor
sec
rol
sta myVALUE
iny
lda ($86),y
and myVALUE
jmp PRBYTE
*---
myVALUE ds 1
*----------------------------
* EDITOR / FIND
*----------------------------
doFIND LDA #$0D
STA $25
JSR VTABZ
LDA #$1F
STA $24
LDY #$00
L2E99 LDA L2F18,Y
INY
CMP #$A6
BEQ L2EA7
JSR COUT1
JMP L2E99
L2EA7 LDA #$0E
STA $25
JSR VTABZ
LDA #$1F
STA $24
LDX #$02 ; nb of chars
L2EB4 JSR RDKEY
CMP #$8D
BEQ L2EEF
JSR COUT1
CMP #$A0
BEQ L2EB4
JSR L2EFF
BCC L2ED6
L2EC7 LDA #$87
JSR COUT1
LDA #$05
STA $22
JSR HOME
JMP L2B2A
L2ED6 ROL
ROL
ROL
ROL
STA $19
JSR RDKEY
JSR COUT1
JSR L2EFF
BCS L2EC7
ORA $19
STA $035A,X
DEX
BPL L2EB4
L2EEF JSR CLREOL
DEC $86
LDA $86
CMP #$FF
BNE L2EFC
DEC $87
L2EFC JMP L2F20
L2EFF CMP #$B0
BMI L2F16
CMP #$BA
BMI L2F12
CMP #$C1
BMI L2F16
CMP #$C7
BPL L2F16
CLC
ADC #$09
L2F12 AND #$0F
CLC
RTS
L2F16 SEC
RTS
L2F18 inv 'FIND:'
ASC "&"
*----------------------------
* EDITOR / REPEAT FIND
*----------------------------
doREPEATFIND LDX #$FF
L2F20 INC $86
BNE L2F34
INC $87
SEC
LDA $14
SBC $86
LDA $17
SBC $87
BCS L2F34
JMP doEND
L2F34 TXA
BMI L2F3F
LDA #$00
L2F39 STA $035A,X
DEX
BPL L2F39
L2F3F LDX #$02
LDY #$00
L2F43 LDA #$BF
CMP $87
BCS L2F4C
JMP doEND
L2F4C LDA $035A,X
BEQ L2F8C
EOR ($86),Y
AND #$7F
BNE L2F5C
DEX
BMI L2F6D
BPL L2F5E
L2F5C LDX #$02
L2F5E INC $86
BNE L2F43
INC $87
SEC
LDA $17
SBC $87
BCC doEND
BCS L2F43
L2F6D LDA $86
LDY $035B
BEQ L2F80
SEC
SBC #$02
BCS L2F7B
DEC $87
L2F7B STA $86
JMP L2B2A
L2F80 SEC
SBC #$01
BCS L2F87
DEC $87
L2F87 STA $86
JMP L2B2A
L2F8C DEX
BMI L2F6D
BPL L2F43
*----------------------------
* EDITOR / GOTO END TRACK
*----------------------------
doEND LDA $14
STA $86
LDA $17
CMP #$C0
BCC L2F9D
LDA #$BF
L2F9D STA $87
JMP L2B2A
*----------------------------
* EDITOR / QUIT EDITOR
*----------------------------
doQUITEDITOR PLA
PLA
PLA
PLA
LDA #$00
STA $0359
JMP L0900
*----------------------------
* EDITOR / HELP
*----------------------------
doHELP LDA #$04
STA $22
LDA #$10
STA $23
JSR HOME
LDY #$00
L2FBB LDA L2FF0,Y
INY
CMP #$A6
BEQ L2FC9
JSR COUT1
JMP L2FBB
L2FC9 LDY #$00
L2FCB LDA L30C0,Y
INY
CMP #$A6
BEQ L2FD9
JSR COUT1
JMP L2FCB
L2FD9 LDA KBDSTROBE
L2FDC LDA KBD
BPL L2FDC
CMP #$8D
BNE L2FD9
JSR HOME
LDA #$01
STA $0359
JMP L1976
L2FF0 ASC " NIBBLE EDITOR COMMANDS"8D8D
ASC " BEGINING "02
ASC " "03
ASC " CHANGE NIBBLE"8D
ASC " UP 32 "14
ASC " "06
ASC " FIND NIBBLES"8D
ASC " UP "09
ASC " "12
ASC " REPEAT FIND"8D
ASC " LEFT "0A
ASC " "0B
ASC " RIGHT"8D
ASC " DOWN "0D
ASC " "13
ASC " TOGGLE SYNC&"
L30C0 ASC 8D
ASC " DOWN 32 "16
ASC " "11
ASC " NEXT TRACK"8D
ASC " END "05
ASC " "
ASC '?'
ASC " HELP"8D
ASC " RESET BEG "0314120C
ASC '-'02
ASC " "10
ASC " PRINT TRACK"8D
ASC " RESET END "0314120C
ASC '-'05
ASC " "12140E
ASC " RETURN TO EDIT&"
*----------------------------
* EDITOR / TOGGLE SYNC
*----------------------------
doTOGGLESYNC TYA
PHA
LDY #$00
LDA ($86),Y
EOR #$80
STA ($86),Y
PLA
TAY
JSR L323B
JMP L2B2A
*----------------------------
* EDITOR / MOVE RIGHT DOWN
*----------------------------
doRIDO TXA
CLC
ADC $86
STA $86
BCC L316F
INC $87
L316F SEC
LDA $87
SBC $0D
BCC L3186
LDA #$87
JSR COUT1
LDA $0D
SEC
SBC #$01
STA $87
LDA #$FF
STA $86
L3186 JMP L2B2A
*----------------------------
* EDITOR / MOVE LEFT UP
*----------------------------
doLEUP STX $00
LDA $86
SEC
SBC $00
STA $86
BCS L3196
DEC $87
L3196 LDA $0D
SEC
SBC $0378
SBC $87
BEQ L31B3
BCC L31B3
LDA #$87
JSR COUT1
LDA $0D
SEC
SBC $0378
STA $87
LDA #$00
STA $86
L31B3 JMP L2B2A
*----------------------------
* EDITOR / CHANGE NIBBLE
*----------------------------
doCHANGENIBBLE JSR SETINV
LDA #$06
STA $25
JSR VTABZ
LDA #$1F
STA $24
LDY #$00
L31C6 LDA L31F4,Y
INY
CMP #$A6
BEQ L31D4
JSR COUT1
JMP L31C6
L31D4 JSR SETNORM
LDA #$06
STA $20
LDA $8C
STA $21
LDA $8B
SEC
SBC #$06
STA $24
TAY
LDA #$0A
STA $25
JSR VTABZ
JSR GETLN1
JMP L31FB
L31F4 ASC "CHANGE&"
L31FB LDY #$00
STY $34
L31FF LDY $34
JSR GETNUM
STY $34
TXA
BEQ L3227
DEY
LDA $0200,Y
CMP #$A0
BEQ L3216
CMP #$8D
BNE L3227
CLC
L3216 LDA $3E
LDY #$00
STA ($86),Y
BCC L3227
INC $86
BNE L31FF
INC $87
JMP L31FF
L3227 JSR L323B
JMP L2B2A
L322D LDA KBD
BPL L322D
LDY #$06
L3234 DEY
BNE L3234
STA KBDSTROBE
RTS
L323B LDA #$00
STA $20
LDA #$28
STA $21
RTS
*----------------------------
* EDITOR / RESET BEGIN TRACK
*----------------------------
doRESETBEGIN LDA $87
STA $0F
LDA $86
STA $0E
LDA #$01
STA $0359
JMP L1976
*----------------------------
* EDITOR / RESET END TRACK
*----------------------------
doRESETEND LDA $86
STA $14
LDA $87
STA $17
LDA #$01
STA $0359
JMP L1976
*----------------------------
* VARIABLES
*----------------------------
fgOUTPUT ds 1
SLOT16 ds 1
ds \