C64 Software  <  SCA: The C64 Software Collection / SCATITEL86/G

  Run
1000              ;
1010              ;
1020              ;SAVE"",8
1030              ;
1040              ; SCA TITEL V2.16
1050              ;
1060              ; 19.11. 1985,
1070              ; 13. 1. 1986
1080              ; 27. 1. 1986
1090              ;
1100              ; RUECKSPRUNG NACH
1110              ; 32000
1120              ;                  
1130              ;
1140              ;
1150              ORG 820
1160              ;
1170 COLPTR       EQU 160
1180 FLASH        EQU 161
1190 TEXTPTR      EQU 87
1200 JOBCNTR      EQU 89
1210 MODE         EQU 90
1220 TMP1         EQU 91
1230 TMP2         EQU 93
1240              ;
1250 F            EQU 3   ; SCROLLFARBE
1260              ;
1270 FILEPAR      EQU $FFBA
1280 FILENAM      EQU $FFBD
1290 OPEN         EQU $FFC0
1300 CHKIN        EQU $FFC6
1310 CKOUT        EQU $FFC9
1320 CLRCH        EQU $FFCC
1330 BSOUT        EQU $F1CA
1340 CLALL        EQU $FFE7
1350              ;
1360 IO           EQU 56576
1370 ST           EQU 144
1380 PTR          EQU 174
1390 CNT          EQU 252
1400 LO           EQU 253
1410 HI           EQU 254
1420 TTP          EQU 255
1430 PPU          EQU 49152
1440              ;
1450 PU           EQU 768
1460 TMP          EQU 68
1470 STMP         EQU 139
1480              ;
1490              ;
1500 BSP          EQU 2048
1510 SPRITEPTR    EQU BSP+1016
1520 SPD          EQU 3072  ; 49 FF
1530              ;
1540 SOUNDINIT    EQU 20480
1550 SOUNDJOB     EQU 20492
1560              ;
1570              ;
1580              ;
1590 INIT         LDA #1    ;TIMERIRQ
1600              STA 56333 ;ABSCHALTEN
1610              ;
1620              LDA #55
1630              STA 1
1640              JSR SYNC
1650              ;
1660              LDA #%00111111
1670              STA IO+2
1680              LDA IO
1690              ORA #3
1700              STA IO
1710              LDA #0
1720              STA 53265
1730              STA 53280
1740              ;
1750              ;
1760              JSR CLALL
1770              LDA #2
1780              LDX #8
1790              TAY
1800              JSR FILEPAR
1810              LDA #2
1820              LDX #<NAME2  ;#3
1830              LDY #>NAME2
1840              JSR FILENAM
1850              JSR OPEN
1860              ;
1870              LDA #15
1880              LDX #8
1890              TAY
1900              JSR FILEPAR
1910              LDA #7
1920              LDX #<NAME15 ;B-P 2 0
1930              LDY #>NAME15
1940              JSR FILENAM
1950              JSR OPEN
1960              ;
1970              LDX #2
1980              JSR CKOUT
1990              LDX #0
2000 UEBERM1      LDA FLOPPYPRG,X
2010              JSR BSOUT
2020              INX
2030              CPX #220
2040              BCC UEBERM1
2050              JSR CLRCH
2060              ;
2070              LDX #15
2080              JSR CKOUT
2090              LDX #5
2100 UEBERM2      LDA ME,X
2110              JSR BSOUT
2120              DEX
2130              BPL UEBERM2
2140              JSR CLRCH
2150              ;
2160              ;
2170              ;
2180              SEI
2190              LDY #46
2200 INIT1        LDA VICTAB,Y
2210              STA 53248,Y
2220              DEY
2230              BPL INIT1
2240              ;
2250              INY
2260              TYA
2270 INIT2        STA $DA30,Y
2280              STA $DB00,Y
2290              DEY
2300              BNE INIT2
2310              LDA #11   ; GRAU FUER
2320              STA $DBE1 ; DATUM
2330              STA $DBE2
2340              STA $DBE3
2350              STA $DBE4
2360              ;
2370              ;
2380 INIT3        STY COLPTR
2390              LDA #100
2400              STA FLASH
2410              ;
2420              LDA #>ISR
2430              STA 789
2440              LDA #<ISR
2450              STA 788
2460              ;
2470              LDA #0
2480              JSR SOUNDINIT
2490              ;
2500              ;
2510              LDA #1
2520              STA JOBCNTR
2530              LDA 53273 ; REQUEST
2540              STA 53273 ; LOESCHEN
2550              LDA #59
2560              STA MODE
2570              LDA #<TEXT
2580              STA TEXTPTR
2590              LDA #>TEXT
2600              STA TEXTPTR+1
2610              ;
2620              ;
2630              LDY #14
2640 INIT4        JSR SYNC
2650              DEY
2660              BMI INIT4
2670              CLI
2680              ;
2690 CRASH        LDX #INIT4-INIT+9
2700              LDA #32
2710 CRASH1       STA INIT,X
2720              DEX
2730              BNE CRASH1
2740              ;
2750              ;
2760 LOAD         LDA IO
2770              AND #%00000011
2780              STA HI
2790              STA IO
2800              ORA #%00010000
2810              STA LO
2820              LDY #0
2830              STY ST
2840              ;
2850 LOAD01       INY
2860              BNE LOAD01
2870              ;
2880              JSR GETBYTE
2890              LDA #1
2900              STA PTR
2910              JSR GETBYTE
2920              LDA #97
2930              STA PTR+1
2940              ;
2950 LOAD02       JSR GETBYTE
2960              SEI
2970              LDX #52
2980              STX 1
2990              STA (PTR),Y
3000              LDX #55
3010              STX 1
3020              CLI
3030              INC PTR
3040              BNE LOAD03
3050              INC PTR+1
3060 LOAD03       LDA ST
3070              BEQ LOAD02
3080              ;
3090              LDA PTR
3100              STA 45
3110              LDA PTR+1
3120              STA 46
3130              JMP ENDE
3140              ;
3150              ;
3160              ;
3170 GETBYTE      LDA #8
3180              STA CNT
3190              ;
3200 GET01        BIT IO
3210              BVS GET02  ; CL   HI
3220              BMI GET01  ; DATA HI
3230              ;
3240              LDA #64    ; ENDE
3250              STA ST
3260              RTS
3270              ;
3280              ;
3290 GET02        LDX LO
3300              LDA IO
3310              STX IO     ; CL LOW
3320              ASL
3330              ROL TTP
3340              NOP
3350              ;
3360              LDX HI
3370              STX IO     ; CL HI
3380              NOP
3390              NOP
3400              ;
3410              DEC CNT
3420              BNE GET02
3430              ;
3440              LDA TTP
3450              EOR #255
3460              ;
3470              RTS
3480              ;
3490              ;
3500              ;
3510 ENDE         JSR SYNC
3520              ;
3530 ENDE0        SEI
3540              LDA #11
3550              STA 53265
3560              LDA #128
3570              STA 53274
3580              ORA #1
3590              STA 56333
3600              LDX #255
3610              STX 56322
3620              INX
3630              STX 54296
3640              LDA #52
3650              STA 1
3660              ;
3670              LDX #127
3680 ENDE1        LDA EXIT,X
3690              STA 512,X
3700              DEX
3710              BPL ENDE1
3720              ;
3730              LDA #1
3740              LDX #97
3750              STA TMP1
3760              STX TMP1+1
3770              STA TMP2
3780              LDX #8
3790              STX TMP2+1
3800              LDY #0
3810              JMP 512
3820              ;
3830              ;
3840 SYNC         LDA 53265
3850              BMI SYNC
3860              LDA 53266
3870              BNE SYNC
3880              RTS
3890              ;
3900              ;
3910              ;
3920 ISR          LDA 53273
3930              STA 53273
3940              LDX JOBCNTR
3950              BEQ JOB0
3960              CPX #1
3970              BEQ JOB1
3980              BNE JOB2
3990              ;
4000 JOB0         LDA #216   ; MULTICOL
4010              STA 53270
4020              JSR SOUNDJOB
4030              JMP JOBAUS
4040              ;
4050              ;
4060 JOB1         LDA 53265
4070              AND #%11110111 ; 24 Z
4080              STA 53265
4090              LDA #127
4100              STA 53269
4110              BNE JOBAUS
4120              ;
4130 JOB2         LDA MODE
4140              ORA #8         ; 25 Z
4150              STA 53265
4160              LDA #0
4170              STA 53269
4180              LDA #200      ; HIRES
4190              STA 53270
4200              ;
4210              INC FLASH
4220              BNE JOBAUS
4230              ;
4240              LDA #234
4250              STA FLASH
4260              LDX COLPTR
4270              INX
4280              CPX #7
4290              BNE JOB21
4300              LDX #0
4310 JOB21        STX COLPTR
4320              ;
4330              LDY #200
4340              LDA COLOR,X
4350 JOB23        STA 55848,Y
4360              STA 56047,Y
4370              DEY
4380              BNE JOB23
4390              ;
4400              ;
4410 JOBAUS       LDX JOBCNTR
4420              INX
4430              CPX #3
4440              BNE JOBAUS1
4450              LDX #0
4460 JOBAUS1      STX JOBCNTR
4470              ;
4480              LDA RASTERTABL,X
4490              STA 53266
4500              LDA 53265
4510              AND #%01111111
4520              ORA RASTERTABH,X
4530              STA 53265
4540              ;
4550              TXA
4560              BNE ISRAUS
4570              ;
4580              JSR MOVE
4590              JSR MOVE
4600              JSR MOVE
4610              ;
4620 ISRAUS       PLA
4630              TAY
4640              PLA
4650              TAX
4660              PLA
4670              RTI
4680              ;
4690              ;
4700              ;
4710 MOVE         LDA 53248
4720              CMP #9
4730              BCC SCLOLL
4740              LDX #64
4750              CMP #17
4760              BCC MOVE1
4770              LDX #96
4780 MOVE1        STX 53264
4790              ;
4800              LDX #14
4810 MOVE2        DEC 53248,X
4820              DEX
4830              DEX
4840              BPL MOVE2
4850              RTS
4860              ;
4870 SCLOLL       LDX #16
4880 SC0          LDA VICTAB,X
4890              STA 53248,X
4900              DEX
4910              BPL SC0
4920              ;
4930              LDA #<SPD+2
4940              LDX #>SPD
4950              STA TMP1
4960              STX TMP1+1
4970              CLC
4980              ADC #62
4990              STA TMP2
5000              BCC SCLOLL1
5010              INX
5020 SCLOLL1      STX TMP2+1
5030              ;
5040              LDX #7
5050 SCLOLLL      LDY #0
5060 SCLOLL2      LDA (TMP2),Y
5070              STA (TMP1),Y
5080              INY
5090              INY
5100              INY
5110              CPY #24
5120              BCC SCLOLL2
5130              ;
5140              LDY #0
5150 SCLOLL3      INY
5160              LDA (TMP2),Y
5170              DEY
5180              STA (TMP2),Y
5190              INY
5200              CPY #24
5210              BCC SCLOLL3
5220              ;
5230              LDA TMP1
5240              CLC
5250              ADC #64
5260              STA TMP1
5270              BCC SCLOLL4
5280              INC TMP1+1
5290 SCLOLL4      LDA TMP2
5300              CLC
5310              ADC #64
5320              STA TMP2
5330              BCC SCLOLL5
5340              INC TMP2+1
5350              ;
5360 SCLOLL5      DEX
5370              BNE SCLOLLL
5380              ;
5390              ;
5400              LDY #0
5410 SCLOLL6      LDA (TEXTPTR),Y
5420              BNE SCLOLL7
5430              ;
5440              LDA #<TEXT
5450              STA TEXTPTR
5460              LDA #>TEXT
5470              STA TEXTPTR+1
5480              BNE SCLOLL6
5490              ;
5500 SCLOLL7      INC TEXTPTR
5510              BNE SCLOLL7A
5520              INC TEXTPTR+1
5530              ;
5540 SCLOLL7A     LDY #27
5550              STY TMP1+1
5560              ASL
5570              ROL TMP1+1
5580              ASL
5590              ROL TMP1+1
5600              ASL
5610              ROL TMP1+1
5620              STA TMP1
5630              ;
5640              LDA #51
5650              STA 1
5660              LDY #7
5670              LDX #23
5680 SCLOLL8      LDA (TMP1),Y
5690              STA SPD+448,X
5700              DEX
5710              DEX
5720              DEX
5730              DEY
5740              BPL SCLOLL8
5750              LDA #55
5760 SCLOLL9      STA 1
5770              ;
5780              RTS
5790              ;
5800              ;
5810 EXIT         LDA (TMP1),Y
5820              STA (TMP2),Y
5830              INY
5840              BNE EXIT
5850              INC TMP1+1
5860              INC TMP2+1
5870              BNE EXIT
5880              ;
5890              LDA #55
5900              STA 1
5910              LDA #4
5920              STA 648
5930              JSR $FD15 ; I/O.VEKT.
5940              JSR $E453 ; BAS.VEKT.
5950              JSR $FFCC ; CLRCH
5960              CLI
5970              JMP 32000
5980              ;
5990              ;
6000              ;
6010 RASTERTABL   DFB 150,248,1
6020 RASTERTABH   DFB 0,0,0
6030              ;
6040 COLOR        DFB 2,7,5,3,14,4,6
6050              ;
6060 CODE4        DFB 0;29
6070              ;
6080 VICTAB       DFB 23,11,71,11,119,11,167,11,215,11,7,11,55,11,0,0,96
6090              DFB 43,248,0,0,127,200,255,40,0,1,0,0,127
6100              DFB 0,0,0,0,0,0,0,0,0,F,F,F,F,F,F,F,F
6110              ;
6120 NAME2        DFB ""
6130 NAME15       DFB ""
6140              ;
6150 ME           DFB 13,6,0,""
6160              ;
6170              ;
6180              ;
6190 TEXT         DFB ""
6200              DFB ""
6210              DFB ""
6220              DFB ""
6230              DFB ""
6240              DFB ""
6250              DFB ""
6260              DFB ""
6270              DFB ""
6280              DFB ""
6290              DFB "",0
6300              ;
6310              ;
6320              ORG SPRITEPTR
6330              DFB 49,50,51,52,53,54,55,56
6340              ;
6350              ;
6360              ;
6370              ORG 17920 ; $0600
6380              ;
6390 FLOPPYPRG    SEI
6400              ;
6410              LDX #17 ;ANFANGSTRACK
6420              LDY #1  ;SEKTOR
6430              ;
6440              ;
6450 FL01         LDA #%00001000 ;CL L
6460              STA 6144
6470              ;
6480              LDA 7168
6490              EOR #%00001000 ;LED
6500              STA 7168
6510              ;
6520              JSR READ
6530              ;
6540              LDA 7168
6550              EOR #%00001000 ;LED
6560              STA 7168
6570              ;
6580              LDY #0
6590              LDX #254
6600              LDA PU
6610              BNE FL02
6620              LDX PU+1
6630 FL02         STX STMP
6640              ;
6650 FL03         LDA PU+2,Y
6660              JSR SENDBT
6670              INY
6680              CPY STMP
6690              BNE FL03
6700              ;
6710              LDX PU
6720              BEQ THEEND
6730              ;
6740              LDY PU+1
6750              JMP FL01
6760              ;
6770              ;
6780 THEEND       LDA #%00001010 ;D,C:L
6790              STA 6144
6800              INX
6810              BNE THEEND
6820              ;
6830              JMP (65532)
6840              ;
6850              ;
6860 SENDBT       STA TMP
6870              ;
6880              LDX #8
6890              ;
6900 SENDBT1      ROL TMP
6910              ROL
6920              ROL
6930              AND #%00000010
6940              STA 6144
6950              ;
6960 SENDBT2      LDA 6144
6970              AND #4       ;CL
6980              BNE SENDBT2  ;HI
6990 SENDBT3      LDA 6144
7000              AND #4       ;CL
7010              BEQ SENDBT3  ;LO
7020              ;
7030              DEX
7040              BNE SENDBT1
7050              ;
7060              RTS
7070              ;
7080              ;
7090              ;
7100 READ         STX 6
7110              STY 7
7120              LDA #128
7130              STA 0
7140              CLI
7150 READ1        LDA 0
7160              BMI READ1
7170              SEI
7180              RTS
READY.