home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 195 / 195.d81 / t.tyb-64 < prev    next >
Encoding:
Text File  |  2000-01-01  |  12.0 KB  |  414 lines

  1.  
  2.  
  3.         TINY YELLOW BROTHER
  4.  
  5.              (TYB-C64)
  6.  
  7.   Program and Text by Doreen Horne
  8.  
  9.      ML Module by Craig Bruce
  10.           and Doreen Horne
  11.  
  12.  
  13.     This is an adaption for the C64
  14. of Craig Bruce's C128 program LITTLE
  15. RED READER which transfers files
  16. between MSDOS and CBM formats. TYB
  17. requires that MSDOS disk operations
  18. be done on a 1581 or compatible
  19. drive. On the CBM side any drive can
  20. be used.
  21.  
  22.     Being for the C64 has imposed
  23. certain restrictions on the number of
  24. MSDOS and CBM files that can be
  25. handled. The C128 has the great
  26. advantage of being able to store its
  27. BASIC variables in BANK1 and use the
  28. whole of BANK0 from $1C01 to $FF00 or
  29. thereabouts for both a BASIC program
  30. and storage space.
  31.  
  32.     The TYB-C64 BASIC program, whilst
  33. based on the original LLR for the
  34. C128 has had to be trimmed severely
  35. (couldn't compete at all with the
  36. expanded V2.7 on LS C128#41). To
  37. provide more memory for BASIC
  38. variables TYB has its binary code at
  39. $C000. Other than that I only made
  40. such alterations as were necessary
  41. for the C64 (some locations in zero
  42. page which were used for storage of
  43. machine code variables by the C128
  44. cannot be used for this purpose by
  45. the C64 and vice versa). Also the
  46. burst protocol which the 1581 and
  47. compatible drives can use when driven
  48. by a C128 had to be replaced by other
  49. code.
  50.  
  51.     Even the SUPER CPU/C64 cannot
  52. increase the the clock speed of the
  53. C64's serial port to the necessary 2
  54. Mhz required for the burst protocol
  55. used by LRR when accessing MSDOS
  56. disks. (I confirmed this with CMD).
  57.  
  58.     Using the replacement code, TYB-
  59. C64 does not need Jiffy-DOS anywhere
  60. at all but transfer speed is much
  61. improved when Jiffy-DOS is involved
  62. and Fender has confirmed that it runs
  63. successfully even with RAMLink.
  64.  
  65.     You may ask why a C64 version at
  66. all? My C128 equipment is slowly
  67. giving up. I already have two C128C
  68. keyboards and a 1571 drive out of
  69. action and have only my C128D still
  70. in working order. Secondhand
  71. equipment is hard to come by and no
  72. one is able and willing (and has
  73. spares) to repair that which comes to
  74. a halt. Australia is PC country!
  75.  
  76.     I found to my dismay that the BIG
  77. BLUE READER/C64 will not even read a
  78. disk directory file which is longer
  79. than 1000 (probably 1023) blocks so
  80. the only way forward is to make the
  81. hardy C64 (with the assistance of
  82. Craig Bruce's adapted LRR) do the
  83. job.
  84.  
  85.     As the newer PCs run only on 3.5
  86. inch disks there seems no point in
  87. including code for 5.25 inch MSDOS
  88. disks. TYB-C64 needs two drives and
  89. whatever does the MSDOS work needs to
  90. be 1581 compatible. The 1581 will
  91. write only to a 3.5 inch disk
  92. formatted in 720K MSDOS format.
  93. WINDOWS does this for me. However if
  94. an FD is used for MSDOS writing, like
  95. LRR, TYB will write to a disk in the
  96. high density 1.4M format.
  97.  
  98.     The maximum number of MSDOS files
  99. that can be accessed is the first 30
  100. on the disk and likewise the first 30
  101. on the CBM disk. This had to be done
  102. to avoid "out of memory" problems and
  103. interminable garbage collections by
  104. the C64. Everything else works much
  105. the same as does LRR. Available free
  106. disk space is the only limit to the
  107. size of files which can be
  108. transferred. These transfer from disk
  109. to disk via a memory buffer of 1024
  110. bytes.
  111.  
  112.     For those who may not have used
  113. LRR what follows are some quick "how
  114. to use" instructions. More "how it
  115. works" information is found in
  116. Craig's docs on LS 128 #41.
  117.  
  118.     The program always reverts to one
  119. of the two main screens, either the
  120. MSDOS directory screen or the one for
  121. the C64 directory. As with LRR the
  122. program can be used as an ordinary
  123. file copier but if you intend getting
  124. involved with MSDOS transfers then
  125. the first thing to do is decide the
  126. device numbers of your CBM and MSDOS
  127. drives, using the F and M keys
  128. respectively. 
  129.     With device numbers selected
  130. ensure you are in the MSDOS screen
  131. (see top left hand corner) then type
  132. D to load the MSDOS directory even if
  133. it is at that stage an empty
  134. formatted disk.
  135.  
  136.  
  137.  [CBM to MSDOS]
  138.  [{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}]
  139.  
  140.     To transfer files from the CBM
  141. disk to the MSDOS disk use the swap
  142. key "/" (slash) to produce the CBM
  143. screen, then use D to access the CBM
  144. directory.
  145.  
  146.     The files will be presented as
  147. BIN(ary)/P(RG) or ASC(ii)/S(EQ)
  148. depending on their type in the CBM
  149. directory. All SEQ files (shown as
  150. ASC) will be translated to TRUEASCII
  151. by the program unless the ASC is
  152. changed to BIN. If you wish to
  153. transfer the selected file to MSDOS
  154. format to be used by that system as
  155. an "attachment" for further
  156. transmission to a CBM system then the
  157. file information should be changed to
  158. BIN(ary). All files designated BIN
  159. are transferred with data exactly as
  160. saved on the CBM disk.
  161.  
  162.     For use as email on a PC system
  163. it may need translation to TRUEASCII.
  164. Only a file in CBMASCII will
  165. translate correctly so you need to
  166. ensure that the word processor you
  167. use to write this file in the first
  168. place saves the file as CBMASCII and
  169. not screen codes. If the file is
  170. saved as TRUEASCII you won't need
  171. translation and the BIN option should
  172. be selected.
  173.  
  174.     The cursor is at the top of the
  175. column marked S(elect) at first.
  176. Using the T key at this point will
  177. toggle/select for transfer all the
  178. files presented. An "*" is shown
  179. against each. The T key used again
  180. de-selects the lot. Using the CRSR
  181. keys up and down in this column and
  182. typing RETURN alongside a selected
  183. name will produce the "*" against
  184. that name only.
  185.  
  186.     Similarly typing RETURN over BIN
  187. or ASC in the TRN column changes the
  188. translation status of that particular
  189. file.
  190.  
  191.     When the selection process is
  192. complete type C and the files marked
  193. with the "*' will be copied to your
  194. MSDOS disk.
  195.  
  196.  
  197.  [MSDOS to CBM]
  198.  [{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}{SHIFT-*}]
  199.  
  200.     To copy from an MSDOS disk to a
  201. CBM disk ensure that you are using
  202. the MSDOS screen (see top left hand
  203. corner and use "/" to get there if
  204. you are not). Use D to acquire the
  205. directory of the MSDOS disk.
  206.  
  207.     It is presented in much the same
  208. format as the CBM directory and the
  209. selection and TRN columns work in the
  210. same way but should you require the
  211. result as a SEQ file then take the
  212. CRSR key to the TYP column and type
  213. RETURN. Similarly changing BIN to ASC
  214. will ensure its translation from
  215. TRUEASCII to CBMASCII. Use C to copy
  216. when ready and the files will be
  217. saved to your CBM disk.
  218.  
  219.     If there are more than 17 files
  220. in your directories the balance is
  221. shown on the second page and you can
  222. get between the two screens
  223. containing the directory by using the
  224. "+" and "-" keys.
  225.  
  226.  [REMOVE:] When you have the MSDOS
  227. directory on screen you can REMOVE
  228. unwanted files by using R(emove). The
  229. process is irreversible and what is
  230. more this does not make inaccessible
  231. files, if there are any, in the MSDOS
  232. directory available. The "cancelled"
  233. space is only written over when a new
  234. file is saved to the MSDOS disk.
  235. Whilst files transferred to MSDOS use
  236. only 32 bytes in the MSDOS directory,
  237. a file written to the disk by a PC
  238. does on occasion use 64 bytes of
  239. directory space and in the worst case
  240. one could only have 10 files on the
  241. directory available to TYB.
  242.  
  243.  [CBM/CBM COPY:] To use the program
  244. as an ordinary CBM file copier two
  245. drives are still required but two
  246. 1541s will do. Ensure that you have
  247. used the F key to nominate the source
  248. device and have the source directory
  249. available on the CBM screen. If you
  250. wish to change the source disk type D
  251. for a new directory. Select your
  252. files and type X. You will need to
  253. provide the device number of the
  254. destination drive then copying of the
  255. selected files will proceed.
  256.  
  257.     In the MSDOS/CBM copying process
  258. disk errors do happen. MSDOS #255
  259. usually occurs if you try to load the
  260. directory when you still have a CBM
  261. disk in the drive. Change the disk
  262. and type D again. It sometimes also
  263. occurs if you try to read the same
  264. MSDOS disk a second time. Whatever
  265. the situation try typing D again.
  266.  
  267.     Error #3 (no address mark
  268. detected on MSDOS disk) also turns up
  269. sometimes when transferring, which
  270. brings to a halt the copying process
  271. of the file concerned. When this
  272. happens during transfer from MSDOS to
  273. CBM one does sometimes succeed in
  274. getting the job done by having
  275. another go when the screen indicates
  276. that all other files selected have
  277. been dealt with. When re-transferring
  278. to CBM one need not scratch the
  279. incomplete destination file. The
  280. program will do it for you after a
  281. request.
  282.  
  283.     Transferring from CBM to MSDOS is
  284. another matter. If I understand the
  285. original LRR documentation for the
  286. C128 correctly it seems that after
  287. the first fault one can recopy the
  288. file to the same disk although there
  289. appears to be snags about its
  290. subsequent recovery. In my testing I
  291. did not encounter any faults during
  292. this process. If it does occur I will
  293. use a newly formatted MSDOS disk when
  294. trying again, and then endeavour to
  295. transfer back to CBM any prior files
  296. of importance on the questionable
  297. disk for retransfer to a better
  298. disk.
  299.  
  300.     Errors on the CBM side cause the
  301. file being read/written to be closed.
  302. They are reported and are usually
  303. either a READ ERROR (corrupted
  304. sector) or DISK FULL.
  305.  
  306.     There is one other thing which
  307. persons who write files for email on
  308. their CBM word processors have
  309. probably already discovered. Keeping
  310. the filename to eight or less
  311. characters with a trailing .TXT makes
  312. it easier to "insert" into the PC
  313. system. Don't forget the need for
  314. TRUEASCII!
  315.  
  316.     Another interesting fact for
  317. users of a 1581 and MSDOS disks in
  318. 720K format is that the CBM disk has
  319. a larger capacity than the MSDOS
  320. disk. A newly formatted CBM disk with
  321. its 3160 blocks free can hold 808960
  322. bytes whereas the MSDOS disk has only
  323. 730112 bytes (2852 blocks) available
  324. for use. As these are used in units
  325. of 1024 bytes quite a bit gets wasted
  326. if a program ends near the beginning
  327. of a unit. The high density MSDOS
  328. disk works in allocation units of 512
  329. bytes. The CBM using a sector of 256
  330. bytes at a time doesn't waste disk
  331. space to the same extent.
  332.  
  333.     When transferring between CBM and
  334. MSDOS it is a good idea to keep an
  335. eye on the FRE bytes available on the
  336. destination disk. If MSDOS space runs
  337. out an error #00 will be reported.
  338.  
  339.     For generously making his
  340. equipment available to me for testing
  341. with JIFFY-DOS I do thank Merv
  342. Carroll. My thanks too to Ivan Blitz,
  343. who tested the program for me and
  344. made sure that I had the equipment I
  345. needed, and to Reiner Richter who
  346. advised me that he'd been able to
  347. write to and read from high density
  348. MSDOS disks using TYB before I was
  349. even satisfied that I was getting the
  350. correct results on 720K format.
  351.  
  352.     When all seemed to be going well
  353. on our PAL systems, I sent the files
  354. to Fender, only for him to find that
  355. I had managed to create an NTSC/PAL
  356. incompatibility. To Fender my thanks
  357. for repeatedly testing "another
  358. possible correction", usually in the
  359. early hours of his morning, until it
  360. finally all came right.
  361.  
  362.     Endeavouring to convert the
  363. original LRR to work on the C64 gave
  364. my 1581 drives a hard time for
  365. several months whilst I tried to
  366. figure out how to read from and write
  367. to PC disks. Useful available
  368. literature on the subject does not
  369. seem to exist. Without the original
  370. binary code and BASIC program written
  371. by Craig Bruce I probably would never
  372. have got any further than that.
  373.  
  374.     My thanks to him for generously
  375. making his LRR available in the
  376. public domain.
  377.  
  378.   Doreen Horne
  379.   Brisbane, Australia
  380.   August 2000
  381.  
  382.   [FENDER'S POSTMUMBLE:] It's a good
  383. thing email is cheap because Doreen
  384. and I did a lot of it getting this
  385. program ready for publishing. Copying
  386. from MSDOS tp CBM was no problem; it
  387. worked on the first version Doreen
  388. sent, and it worked on every other
  389. version. It was the CBM to MSDOS
  390. copying that gave us fits.
  391.  
  392.  I kept getting corrupted directories
  393. on the MSDOS when I wrote to them on
  394. my high-end system, which has a
  395. SuperCPU and RAMLink. Later versions
  396. would work on my second system, as
  397. long as I disabled RAMLink.
  398.  
  399.  But Doreen persevered (as I knew she
  400. would) and this latest version she
  401. sent works for me on both systems,
  402. with or without RAMLink. The SuperCPU
  403. does have to be switched down to 1
  404. MHz, but that's expected for any
  405. program that does heavy-duty writing,
  406. especially to a foreign disk.
  407.  
  408.  We all have friends and relatives
  409. with PCs. Now, thanks to Doreen Horne
  410. and Craig Bruce, anyone with a
  411. Commodore computer and a 3.5 inch
  412. drive can share files with them.
  413.  
  414.