[Coco] Coco BASIC files
Willard Goosey
goosey at virgo.sdc.org
Fri Dec 19 05:30:28 EST 2003
>Date: Thu, 18 Dec 2003 21:21:46 -0800 (PST)
>From: <arikboke at yahoo.com>
>Folks,
>
>Some please explain to me why BASIC comes in 'BASIC binary" and
>'BASIC ascii'. Are not BASIC sources supposed to be .TXT files?
The binary BASIC files save disk space (usually using one character
per keyword, such as "?" for "PRINT") and load time. This is
"tokenized" form.
>Also, when placed onto virtual diskettes via IMGTOOL in MESS, often
>times I am unable to access said files (neither ASCII nor binary). I
>keep getting "FM? ERROR ..." or some variants. Have they become
>corrupt?
You may have end-of-line problems. Both Color BASIC and OS-9 use
carriage return, control-m, ascii $0D, as EOL. DOS/Windoze uses
linefeed and carriage return, ^j^m as EOL. If your ASCII BASIC got
saved as a DOS text file at some point, this would be a problem. If it
got saved on a UNIX box, you've got real trouble, 'cause they use bare
linefeeds.
The other thing I can think of is that BASIC needs the ASCII/Binary
flag and the file type set correctly. Tokenized BASIC should be type
0, binary. ASCII BASIC can be type 0 or 3, ASCII. Type 1, BASIC
data, may also work.
For reference:
0 BASIC program
1 BASIC data file
2 machine-language file
3 text file
Or imgtool may be broken. I wouldn't know.
>
>Sincerely,
>David
Willard
--
Willard Goosey goosey at sdc.org
Socorro, New Mexico, USA
"I've never been to Contempt! Isn't that somewhere in New Mexico?"
--- Yacko
More information about the Coco
mailing list