home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
8bitfiles.net/archives
/
archives.tar
/
archives
/
genie-commodore-file-library
/
C64Telecom
/
CXTERM-FOR-TAPE
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2019-04-13
|
8KB
|
156 lines
1 POKE45,148:POKE46,37:POKE248,39:POKE250,38:POKE56,38:POKE644,38:CLR
2 POKE157,128:PRINT"[144]":POKE53281,12
3 PRINT"[147]":POKE53280,6:CLR
4 A$=" **************************************"
5 PRINTA$
6 PRINT" [195][216][212][197][210][205] [214]ERSION 1.04 BY [194]OBBY [211]MITH"
7 PRINT" [208]UNTER & [216]MODEM [198]ILE [212]RANSFERS"
8 PRINT" FOR USE WITH DATASETTE"
9 PRINTA$:CLR
10 PRINT" <[212]>ERMINAL MODE"
11 PRINT" <[204]>OAD FILE TO UPLOAD"
12 PRINT" <[213]>PLOAD PREVIOUSLY LOADED FILE"
13 PRINT" <[196]>OWNLOAD A FILE"
14 PRINT" <[211]>AVE DOWNLOADED FILE"
16 PRINT" <[210]>EAD SEQUENTIAL FILE"
17 PRINT" <[209]>UIT":PRINT" ";
18 CO$="TLU[184]DS[188]RQ":GOSUB87:POKE53280,12:ONJGOTO19,24,43,113,57,74,103,128,125
19 PRINT"[147]"
20 PRINT"** [212]ERMINAL MODE. ** ";
21 IFPEEK(5824)=6THENPRINT"(300 BAUD)":GOTO23
22 PRINT"(OPTIONAL BAUD)"
23 SYS5828:GOTO3
24 PRINT"[147]** [204]OAD A FILE. **"
25 FI$="":INPUT"[198]ILENAME";FI$
26 IFFI$=""THEN3
27 PRINT"[198]ILE TYPE:"
28 GOSUB118:ONJGOTO29,34,3
29 PRINT"[208]ROGRAM.":POKE2,80
30 POKE679,LEN(FI$)
31 FORI=1TOLEN(FI$):POKE679+I,ASC(MID$(FI$,I,1)):NEXT
32 SYS5490
33 PRINT:GOTO39
34 PRINT"[211]EQUENTIAL.":POKE2,83
35 OPEN1,1,0,FI$
36 PRINT:PRINT"LOADING";
37 SYS5627
38 CLOSE1:PRINT
39 PRINT"[200]IT <[210][197][212][213][210][206]> TO CONTINUE."
40 POKE198,0
41 GETA$:IFA$<>CHR$(13)THEN41
42 GOTO3
43 PRINT"[147]** [213]PLOAD A FILE. **"
44 E=0:GOSUB114
45 IFETHENPRINT"[206]OTHING TO UPLOAD.":GOTO39
46 PRINT"[208]ROTOCOL:"
47 PRINT" <[216]>MODEM"
48 PRINT" <[208]>UNTER"
49 PRINT" <[193]>BORT"
50 CO$="XPA":GOSUB87:ONJGOTO51,54,3
51 PRINT"[216]MODEM."
52 GOSUB122:SYS7460
53 GOTO3
54 PRINT"[208]UNTER."
55 GOSUB122:SYS8901
56 GOTO3
57 PRINT"[147]** [196]OWNLOAD A FILE. **"
58 PRINT"[208]ROTOCOL:"
59 PRINT" <[216]>MODEM"
60 PRINT" <[208]>UNTER"
61 PRINT" <[193]>BORT"
62 CO$="XPA":GOSUB87:ONJGOTO63,70,3
63 PRINT"[216]MODEM."
64 PRINT"[212]YPE OF FILE BEING DOWNLOADED."
65 GOSUB118:ONJGOTO66,67,3
66 PRINT"[208]ROGRAM.":POKE2,80:GOTO68
67 PRINT"[211]EQUENTIAL.":POKE2,83
68 SYS6886
69 GOTO3
70 PRINT"[208]UNTER."
71 PRINT"[198]ILETYPE: ";
72 SYS8152
73 GOTO3
74 PRINT"[147]** [211]AVE A FILE. **"
75 E=0:GOSUB114
76 IFE=1THENPRINT"[206]OTHING TO SAVE.":GOTO39
77 FI$="":INPUT"[198]ILENAME";FI$
78 IFFI$=""THEN3
79 PRINT"[211]AVE AS:"
80 GOSUB118:ONJGOTO98,81,3
81 PRINT"[211]EQUENTIAL."
82 OPEN1,1,1,FI$
83 PRINT:PRINT"SAVING "FI$
84 SYS5717
85 CLOSE1:PRINT"DONE":GOTO39
86 END
87 PRINT"[211]ELECTION? ";
88 PRINT" [146][157]";
89 FORI=1TO50
90 GETA$:IFA$<>""THENGOSUB96:IFJ<=LEN(CO$)THENRETURN
91 NEXT
92 PRINT" [157]";
93 FORI=1TO50
94 GETA$:IFA$<>""THENGOSUB96:IFJ<=LEN(CO$)THENRETURN
95 NEXT:GOTO88
96 FORJ=1TOLEN(CO$):IFA$<>MID$(CO$,J,1)THENNEXT
97 RETURN
98 PRINT"[208]ROGRAM."
99 POKE679,LEN(FI$)
100 FORI=1TOLEN(FI$):POKE679+I,ASC(MID$(FI$,I,1)):NEXT
101 SYS5676
102 PRINT:PRINT"DONE":GOTO39
103 PRINT"[147]** [195]HANGE OPTIONAL BAUDRATE. **"
104 PRINT"[197]NTER THE VALUES FOR CONTROL, COMMAND,"
105 PRINT"OPT LOW, AND OPT HIGH. [211]EPARATE"
106 PRINT"WITH COMMAS."
107 PRINT"[197]XAMPLES: 110 BAUD = 3,0,0,0"
108 PRINT" 450 BAUD = 0,0,12,4"
109 INPUTA,B,C,D:E=9426:F=5824
110 POKEE,A:POKEE+1,B:POKEE+2,C:POKEE+3,D
111 POKEF,A:POKEF+1,B:POKEF+2,C:POKEF+3,D:PRINT:GOTO3
113 POKE2,83:GOTO43
114 IF(PEEK(2)<>80ANDPEEK(2)<>83)THENE=1
115 IF(PEEK(251)+256*PEEK(252))<10240THENE=1
116 IF(PEEK(253)+256*PEEK(254))<=(PEEK(251)+256*PEEK(252))THENE=1
117 RETURN
118 PRINT" <[208]>ROGRAM"
119 PRINT" <[211]>EQUENTIAL"
120 PRINT" <[193]>BORT"
121 CO$="PSA":GOSUB87:RETURN
122 PRINT"[198]ILETYPE: ";
123 IFPEEK(2)=80THENPRINT"[208]ROGRAM.":RETURN
124 PRINT"[211]EQUENTIAL.":RETURN
125 PRINT"[147]"
126 POKE248,159:POKE250,158:POKE56,158:POKE644,158:CLR
127 PRINT"[199]OODBYE...":END
128 PRINT"[147]"
129 PRINT"** [210]EAD SEQUENTIAL FILE. **"
130 A=6498:PRINT"[198]ROM:"
131 PRINT" <[205]>EMORY"
132 PRINT" <[212]>APE"
133 PRINT" <[193]>BORT"
134 E=0:CO$="MTA":GOSUB87:ONJGOTO135,144,3
135 PRINT"[205]EMORY.":GOSUB115
136 IFPEEK(2)<>83THENE=1
137 IFETHENPRINT"[206]O SEQUENTIAL FILE IN MEMORY TO READ.":GOTO39
138 S=PEEK(251)+256*PEEK(252)
139 F=PEEK(253)+256*PEEK(254)-1
140 FORI=STOF
141 PRINTCHR$(PEEK(A+PEEK(I)));
142 GOSUB152:IFETHENI=F
143 NEXT:PRINT:GOTO39
144 PRINT"[212]APE."
145 F$="":INPUT"[198]ILENAME";F$
146 IFF$=""THEN3
147 OPEN1,1,0,F$:PRINT""
148 GET#1,A$:PRINTCHR$(PEEK(A+ASC(A$)));
149 GOSUB152:IFETHEN151
150 IFST=0THEN148
151 CLOSE1:PRINT:GOTO39
152 POKE212,0:GETA$:IFA$=""THENRETURN
153 IFA$=" "THEN156
154 IFA$="A"THENE=1
155 RETURN
156 GETA$:IFA$<>" "THEN156
157 RETURN