aboutsummaryrefslogtreecommitdiff
path: root/AMSB.txt
diff options
context:
space:
mode:
Diffstat (limited to 'AMSB.txt')
-rw-r--r--AMSB.txt41
1 files changed, 40 insertions, 1 deletions
diff --git a/AMSB.txt b/AMSB.txt
index aa83799..aa721af 100644
--- a/AMSB.txt
+++ b/AMSB.txt
@@ -72,7 +72,43 @@ depends on what MEMLO was set to when the program was saved (which varies
depending on what version of AMSB you have, what DOS you boot, whether
or not you have the R: device driver loaded, etc etc).
-Notes:
+LOADing Untokenized Files
+-------------------------
+
+If the first byte of the file is anything other than $00 or $01,
+AMSB's LOAD command reads it in as a text file (LISTed rather than
+SAVEd).
+
+When LOAD is reading a text file, if the last byte of the file isn't
+an ATASCII EOL ($9b), you'll get #136 ERROR. The program doesn't get
+deleted, but the last line of the file didn't get loaded. This could
+happen if a LISTed file somehow got truncated.
+
+While on the subject... the manual doesn't mention it, but if you LOAD
+a text file without line numbers, the code gets executed in direct
+mode during the load (like Atari BASIC's ENTER command does). This
+means you could write scripts (batch files) for AMSB.
+
+Program Length Header Mismatch
+------------------------------
+
+When AMSB's LOAD command executes, it reads the 3-byte header, then
+reads as many bytes as the header's program length says.
+
+If the header length is longer than the rest of the file, you get
+a #136 ERROR (aka Atari's EOF), and the partially loaded program is
+erased (basically it does a NEW).
+
+If the length is shorter than the program, it'll stop loading no
+matter how much more data is in the file. This means it can stop in
+the middle of a line. It also means, if there was already a program in
+memory that was longer than the program length, you get a "hybrid" mix
+of the new program followed by the remainder of the old one. This is
+because the three $00 bytes at the end of the program weren't read in.
+
+If the program length is correct for the actual program (so the three
+$00 bytes get read), but there's extra data appended to the file, AMSB
+will never read the extra data at all.
String Limitations
------------------
@@ -144,6 +180,9 @@ returned by NOTE are used with AT() in a PRINT statement. Not sure
if AT() works without the extensions loaded, but it won't be useful
anyway without NOTE.
+One other difference between versions 1 and 2: version 2 will LOAD and
+RUN the file D:AUTORUN.AMB at startup, if it exists.
+
Comment Tokenization
--------------------