Article 56726 of comp.sys.cbm:
Xref: undergrad.math.uwaterloo.ca comp.sys.cbm:56726
Newsgroups: comp.sys.cbm
Path: undergrad.math.uwaterloo.ca!csbruce
From: csbruce@ccnga.uwaterloo.ca (Craig Bruce)
Subject: Re: How to transfer files from PC to C64?
Sender: news@undergrad.math.uwaterloo.ca (news spool owner)
Message-ID: <DuA5KE.D7K@undergrad.math.uwaterloo.ca>
Date: Tue, 9 Jul 1996 14:29:01 GMT
References: <4rcep2$net@druid.borland.com> <milocco-0507961828030001@140.105.4.232> <4rs2po$iqp@druid.borland.com>
Nntp-Posting-Host: ccnga.uwaterloo.ca
Organization: University of Waterloo, Canada (eh!)

In article <4rs2po$iqp@druid.borland.com>,
Josh Lubliner <squonk@mousehouse.com> wrote:

>milocco@elettra.trieste.it (Andrea MILOCCO) wrote:
>>ftp://ccnga.uwaterloo.ca//pub/cbm/telecomm/xmodem64.zip
>>ftp://ccnga.uwaterloo.ca//pub/cbm/telecomm/xmodem64.readme
>
>Thank you!  That is _exactly_ what I wanted to know.  I tried to reply
>to you through e-mail, but I kept getting bounced.
>
>There is one problem:  That file is apparently corrupted, and I cannot
>unzip it.  I e-mailed the administrator.

The file in question does indeed appear to be corrupted, since it looks very
small and doesn't extract for me either.  But, I think that what's supposed
to be inside of it was posted to this newsgroup in Sept. 1995 by Gaelyne
Moranec.  I have included her article below (which contains the
BASIC-program listing).

Keep on Hackin'!

-Craig Bruce
csbruce@ccnga.uwaterloo.ca
"Never underestimate the power of a simple tool."

C=256,64K-VDC,REU,RL16,HD200,FD4000,SL,USR28.8,C=128,1581,1571,C=64C,1541,VIC20

-----
Article 42103 of comp.sys.cbm:
From: moranec@hal9000.apana.org.au (Gaelyne Moranec)
Newsgroups: comp.sys.cbm
Subject: terminal program for 300
Date: 11 Sep 1995 10:30:39 -0500
Organization: UTexas Mail-to-News Gateway
Lines: 188
Sender: nobody@cs.utexas.edu
Message-ID: <199509111539.BAA26033@hal9000.apana.org.au>
NNTP-Posting-Host: news.cs.utexas.edu

To: comp-sys-cbm@cs.utexas.edu


 CE> has anyone got a listing of a 300 baud
 CE> terminal program? i just lent a
 CE> modem off a friend, but i don't have any
 CE> software... if anyone has a
 CE> program that i can type in (yes, type in,
 CE> currently i don't have a way
 CE> of transferring files from/to the C64), i
 CE> would be happy, happy, happy,

I have one on my web site:

http://www.msen.com/~brain/guest/Gaelyne_Moranec/term.html

I just browsed through it and it doesn't seem to have a baud rate - I
would assume that so long as both computers are using the same baud
rate, the program should work.


   ---------------------   Text Import Start   ---------------------

    Note, I don't know that an ASCII to Basic converter will convert
all properly unless you first remove the bracketed magazine-style
keypresses ( [blue] [shft-home] etc), then put-in the actual keypresses
after the conversion is done (or at least since they are in print
statements, just bear in mind that they are there in that format, and
will need to be entered properly once the thing is in Basic).  But of
course for the original type-in purpose, this is just what the doctor
ordered :-)



10 rem *****************
15 rem * xmodem 64 3.6 *
20 rem *  karl schmitt *
25 rem *****************
30 poke53281,3:poke53280,6:printchr$(151)chr$(14):open5,2,3,chr$
   (6)+chr$(.)
35 open15,8,15:u=212:d=256:w=1:e$=chr$(147):c=250:s=64:p$=chr$
   (19):o=8
40 bl$="[home][5-dn]":er$="[home][8-dn][14 spcs][up]"+chr$(13)
45 ack=6:nak=21:eot=4:can=24:z=131:v=132:f=255:m=288:p=12
50 c$=chr$(.):r$=chr$(18):j$=chr$(13):o$=chr$(18)+chr$(32)+
   chr$(157)+chr$(146)
55 printe$j$"[blue]XMODEM 64"j$
60 print"DOWNLOAD & UPLOAD";:g$=chr$(133):q$=chr$(34):i$=chr$(20)
65 print" TERMINAL PGM"j$j$"DISK VERSION 3.6"j$
70 print"by Karl Schmitt"j$j$
75 print"Hit <f1> For Main Menu."
80 printj$"Use XMODEM protocol for all transfers."j$j$:l$=chr$
   (32)+chr$(157)
85 print"1. Bulletin Board"j$j$"2. 64 to 64"j$j$j$j$
90 print"Type 1 or 2 to begin.":gosub505:ifa$="1"then105
95 ifa$="2"thenb=w:goto105
100 goto90
105 dimf%(f),t%(f),u%(p,v)
110 printe$"Please stand by for 9 seconds."j$j$"Creating Translat
    ion tables."
115 forj=32to64:t%(j)=j:next:t%(13)=13:t%(20)=8:forj=65to90:t%(j)
    =j+32:next
120 forj=91to95:t%(j)=j:next:forj=193to218:t%(j)=j-128:next:t%
    (146)=p
125 t%(133)=p:t%(147)=19:t%(137)=3:t%(134)=17:t%(138)=19:forj=.to
    f:k=t%(j)
130 ifk<>.thenf%(k)=j:f%(k+128)=j
135 next
140 rem------------terminal------------
145 printchr$(14)
150 printe$" Terminal Mode"j$:ifa$=chr$(can)thenprint"Transfer CA
    NCELLED!"
155 iffa=wthenprint"When host is ready to receive, hit f1"j$"for
    main menu and";
160 iffa=wthenfa=.:print" start the upload."j$
165 get#5,a$:ifa$=""then180
170 printl$chr$(f%(asc(a$)));:ifa$=q$thenpokeu,.
175 goto165
180 printo$;:geta$:ifa$=""then165
185 ifb=wthen:x=asc(a$):ifx=13orx=145orx=157orx=29orx=17orx=19
    thenprintl$;
190 ifb=wthenprinta$;:ifa$=q$thenpokeu,.
195 ifa$=g$thenprintl$j$:goto320
200 print#5,chr$(t%(asc(a$)));:goto165
205 rem-----------download-------------
210 printe$"is host computer waiting to send? y/n":gosub505:ifa$=
    "n"then145
215 printj$:ifa$<>"y"then210
220 g=3:k$="w":gosub345:print:bl=.:n=.
225 printj$"downloading  "f$er$"[up]status"
230 forh=wtop
235 ch=.:forx=wtov:get#5,a$:e=st:ifa$=""thenife=othenl=l+w
240 ife=.thenl=.:goto255
245 ifl=mthenl=.:gosub525:printbl$"waiting":goto230
250 goto235
255 ifx=wthenifa$=chr$(eot)thengosub520:goto310
260 u%(h,x)=asc(a$+c$):ch=ch+u%(h,x):next:ch=ch-u%(h,v)
265 if(u%(h,w)+u%(h,2)+u%(h,3)and f)<>.thengosub525:printer$"soh
    error":goto235
270 ifu%(h,v)<>(chandf)thengosub525:printer$"checksum error":
    goto235
275 bl=bl+w:printbl$"block"bl
280 ifu%(h,2)<>blthenbl=bl-1:gosub520:printer$"duplicate bl":
    goto235
285 ifh<>pthengosub520
290 next:h=h-w
295 ifn=wthenifh=.then310
300 fory=1toh:forx=eottoz:print#3,chr$(u%(y,x));:next:next
305 gosub520:goto230
310 fora=wtoh:forr=eottoz:print#3,chr$(u%(a,r));:next:next:close3
    :goto550
315 rem-----------menu-----------------
320 printchr$(142)e$
325 printj$"1. download"j$"2. upload"j$"3. terminal"j$"4. directo
    ry"
330 print"5. start upload"j$"6. end":gosub505
335 onval(a$)goto210,375,145,475,585,515
340 goto325
345 printe$:input"filename e[rvs-on]x[rvs-off]it.";f$:iff$="x"
    then320
350 printe$:input"filetype [rvs-on]p[rvs-off]rogram[space]
    [rvs-on]s[rvs-off]equential e[rvs-on]x[rvs-off]it";ft$:ifft$=
    "x"then320
355 ft$=left$(ft$,w)
360 openg,8,g,"0:"+f$+","+ft$+","+k$:input#15,a,b$:printe$;a;b$:
    ifa=.thenreturn
365 closeg:goto325
370 rem-----------upload---------------
375 g=6:k$="r":gosub345:bl=.:fa=w
380 printer$"[up]reading      ":fory=wtop:u%(y,w)=w
385 bl=bl+w:u%(y,2)=bl:u%(y,3)=f-bl:ch=w+u%(y,2)+u%(y,3):printer$
    "block"bl
390 forx=eottoz:get#6,b$:ifst=.then400
395 fl=y:ch=ch+u%(y,x):fora=x+wtoz:u%(y,a)=.:next:u%(y,v)=chandf:
    goto405
400 u%(y,x)=asc(b$+c$):ch=ch+u%(y,x):next:u%(y,v)=chandf:next:
    y=y-w
405 iffa=wthen145
410 get#5,a$:ifa$<>chr$(nak)then410
415 bl=bl-y:y=.
420 printer$"[up]upload status"j$"nak"bl$"[up]uploading"
425 y=y+w:bl=bl+w
430 printbl$"block"bl:forx=wtov:print#5,chr$(u%(y,x));:next
435 fora=.to1200:get#5,a$:ifa$=""thennext:goto430
440 ifa$=chr$(ack)thenify=pthenprinter$"ack":goto380
445 ifa$=chr$(ack)theniffl<>ythenprinter$"ack":goto425
450 ifa$=chr$(ack)theniffl=ythenfl=.:gosub535:gosub540:close6:
    goto550
455 ifa$=chr$(nak)thenprinter$"nak":goto430
460 ifa$=chr$(can)thenclose6:goto550
465 goto435
470 rem---------directory--------------
475 printe$:open1,8,0,"$0":get#1,a$,a$
480 get#1,a$,a$:ifa$=""then500
485 get#1,a$,b$:printasc(a$+c$)+asc(b$+c$)*d;
490 get#1,a$:ifa$=""thenprint:goto480
495 printa$;:goto490
500 close1:goto325
505 geta$:ifa$=""then505
510 return
515 end
520 print#5,chr$(ack);:printer$"ack":q=.:return
525 q=q+w:ifq=11thenclose3:a$=chr$(can):print#5,a$:goto550
530 print#5,chr$(nak);:printer$"nak":return
535 print#5,chr$(eot);:printer$"eot":return
540 get#5,a$:ifa$=""then540
545 return
550 print"[clr/home]hit any key for terminal mode"
555 so=54272
560 pokeso+1,250:pokeso+5,10:pokeso+15,200
565 pokeso+24,15:forcl=1to12:pokeso+4,21:fortm=1to1250:next:
    pokeso+4,20
570 getb$:ifb$=""then560
575 so=54272:forcl=.to24:pokeso+cl,.:next
580 goto145
585 printe$"is host computer ready to recieve? y/n"j$:gosub505:
    ifa$="n"then145
590 ifa$<>"y"then585
595 printe$"have the first 12 (or less) blocks to[3 spaces]upload
    been read yet ?"
600 gosub505:ifa$="n"then145
605 ifa$<>"y"then595
610 printe$"uploading[2 spaces]"f$:goto405

   ---------------------   Text Import End   ---------------------


