Undocumented 8.1 commands: Difference between revisions
No edit summary |
No edit summary |
||
| Line 77: | Line 77: | ||
|} | |} | ||
<u>Conclusion</u>: “then” statements are not required for “if/then” – <strong>if <condition> <action></strong> is legal in most cases. | <u>Conclusion</u>: “then” statements are not required for “if/then” – <strong>if <condition> <action></strong> is legal in most cases. | ||
|} | |||
<span id="dot9"></span> | |||
{| class="wikitable | |||
|- | |||
! Topic | |||
! Found in | |||
|- | |||
| <strong>.9</strong> | |||
| <strong>All main overlays</strong> | |||
Previously documented in 8.0 documentation as a "do not use" command that replaces "&" function, this appears to be repurposed for single key command input replacing the traditional "gosub110" routine. | |||
''' .9 – Single-Key Command Input Poll ''' | |||
---- | |||
'''Overview''' | |||
The <code>.9</code> command polls for a single keypress and stores the result into the BASIC string variable <code>A$</code>. It is used at the command prompt to capture one-character command input from either the local keyboard or remote modem connection. | |||
Previous iterations of Color 64 used <code>gosub110</code> in the same areas. | |||
---- | |||
'''Behavior (Observed in Live BBS Testing)''' | |||
When a key is pressed: | |||
* <code>A$</code> is set to the key pressed | |||
* The character is stored in high-bit PETSCII format | |||
* Example: | |||
** Pressing "X" → <code>ASC(A$)=216</code> | |||
** Pressing "O" → <code>ASC(A$)=207</code> | |||
::(Standard ASCII value + 128) | |||
When no key is pressed: | |||
* <code>A$=""</code> (empty string) | |||
* The command does not block execution | |||
The command key is read directly from <code>A$</code>. | |||
|} | |||
<span id="dot31"></span> | |||
{| class="wikitable | |||
|- | |||
! Topic | |||
! Found in | |||
|- | |||
| <strong>.31 and !55</strong> | |||
| <strong>√bbs.msgs</strong> | |||
{| class="wikitable | |||
|- | |||
! Example | |||
! 8.0 | |||
! 8.1 | |||
|- | |||
| 1 | |||
| [[File:31and55_ex1_80.png|center|300px]] | |||
| [[File:31and55_ex1_81.png|center|300px]] | |||
|} | |||
<u>Conclusion</u>: .31 – Message-Aware Disk Input (Version 8.1) | |||
Earlier documentation listed the ML command '''.31''' as "not used." Analysis of Version 8.1 confirms this is incorrect. In Color 64 v8.1, the <code>.31</code> command is actively used within message-handling overlays (notably <code>BBS.MSGS</code>) and functions as a specialized form of disk input. It replaces the earlier <strong>.01</strong> disk input command used in Version 8.0 when scanning and reading private messages. | |||
<strong>Comparison: Version 8.0 vs Version 8.1</strong> | |||
{| class="wikitable | |||
|- | |||
! 8.0 | |||
! 8.1 | |||
|- | |||
| style="vertical-align: top;" | Message scanning used: <code>.01</code> | |||
After each read, BASIC code manually checked for a message delimiter: <code>IF @0 = CHR$(14) THEN ...</code>. The byte <code>{0E}</code> ('''CHR$(14)''') acted as the message record separator. When this character was encountered, the system incremented or decremented message counters, control flow moved to the next message record, and the loop continued scanning until completion. The delimiter (end of message) detection was handled explicitly in BASIC. | |||
| style="vertical-align: top;" | In Version 8.1, <code>.01</code> is replaced in message routines by: <code>.31</code>. | |||
The <code>.31</code> command performs the disk input operation and internally detects the message delimiter. Instead of BASIC checking <code>@0 = CHR$(14)</code>, Version 8.1 uses the ML variable <code>IF !55 THEN ...</code>. When <code>!55</code> becomes non-zero, the system has reached the end of the current message record, message counters are updated, and control moves to the next message or exits the loop. Delimiter detection is now handled inside the ML routine rather than in BASIC. | |||
<strong>!55 – Message Record Delimiter Flag</strong> | |||
<code>!55</code> is an ML variable introduced in Version 8.1 that serves as a '''message record boundary flag'''. It is set automatically by <code>.31</code> when the message delimiter byte (previously tested as <code>CHR$(14)</code> in Version 8.0) is encountered. | |||
: <code>!55 = 0</code> → No delimiter encountered | |||
: <code>!55 ≠ 0</code> → End of message record reached | |||
When <code>!55</code> is detected: | |||
* The current message scan loop updates counters | |||
* The system transitions to the next message record | |||
* Display or processing routines advance accordingly | |||
|} | |||
|} | |} | ||
| Line 149: | Line 235: | ||
necessary for normal command entry. Further testing under stress conditions | necessary for normal command entry. Further testing under stress conditions | ||
(typeahead flooding, carrier transitions, mode switching) may reveal its purpose. | (typeahead flooding, carrier transitions, mode switching) may reveal its purpose. | ||
|} | |} | ||
Revision as of 21:37, 19 February 2026
At the time of this revision for Color 64 v8.1a, there are notably several ML related commands and variables that are not documented as well as some basic shortcuts and appear to have been introduced from the 8.1 upgrade. I find that comparing 8.0 code with 8.1 helps you along in figuring out what these undocumented items perform. Below are some of my notes and observations of what the code was in 8.0 and the observed shortcuts implemented in 8.1 Please note it is a work-in-progress and I don’t have all the answers (yet), so some of this is just “observation” without any conclusion!
Getting to understand some of the modified BASIC can be easy. If you have the ML loaded into your system, you can write your own program to test out the modified BASIC by having your first line call the ML routine: SYS49923
10 SYS49923 20 #"Test of program" 30 etc....
Below are some of my observations.
| Topic | Found in |
|---|---|
| Simple Addition | All overlays
Color 64 allows simple addition without using < var >=< same var >+< value > So "a=a+12" can alternately just be: "a+12". This only works with numbers (not strings) and other times, this just fails completely. Buyer beware. |
| Topic | Found in | ||||||
|---|---|---|---|---|---|---|---|
| Use of "THEN" in IF | all
Conclusion: “then” statements are not required for “if/then” – if <condition> <action> is legal in most cases. |
| Topic | Found in |
|---|---|
| .9 | All main overlays
Previously documented in 8.0 documentation as a "do not use" command that replaces "&" function, this appears to be repurposed for single key command input replacing the traditional "gosub110" routine. .9 – Single-Key Command Input Poll Overview The Previous iterations of Color 64 used Behavior (Observed in Live BBS Testing) When a key is pressed:
When no key is pressed:
The command key is read directly from |
| Topic | Found in | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| .31 and !55 | √bbs.msgs
Conclusion: .31 – Message-Aware Disk Input (Version 8.1) Earlier documentation listed the ML command .31 as "not used." Analysis of Version 8.1 confirms this is incorrect. In Color 64 v8.1, the Comparison: Version 8.0 vs Version 8.1
|
| Topic | Found in | ||||||
|---|---|---|---|---|---|---|---|
| .36 | √bbs.init
.36 – Prompt-Cycle Housekeeping (Behavior Unconfirmed) Category: ML Command Seen in: All main overlays (prompt printing routine) Overview The In testing within the live BBS environment, removing Observed Call Pattern
Testing Notes
Working Hypothesis
Summary
|
| Topic | Found in | ||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| .38 / .39 / .40 / .41 and “;” variables | √bbs.msgs
Message Relink Commands in v8.1
.38 – Relink Iterator Initialization (v8.1) The It is designed to be used as the first step in a command sequence:
This sequence replaces the more BASIC-driven record scanning logic found in v8.0. What .38 Does
In BBS.MSGS, this binding typically associates:
The ML iterator then uses internal scratch registers such as:
These are later examined by BASIC to determine loop control and branching. In v8.0, message scanning and linking logic was performed directly in BASIC, including character comparisons and explicit loop control. In v8.1, this logic was moved into machine language for speed and structural cleanliness. BASIC now acts primarily as a decision layer while ML handles the iteration mechanics. Important Notes
Summary The It should be understood as a setup command rather than an action command. |
| Topic | Found in | ||||||
|---|---|---|---|---|---|---|---|
| if...£ | √bbs.msgs
Observation: Observe the 8.1 authors reversed the checks in variable comparisons as the conditions, with end-result being the same. Conclusion: Serves as an “not” function “(lv is not less than cm%(2,2) and lv not less than cm%(29,2) and fr does not equal 1, then print (P)rivate)” Another example:
|
| Topic | Found in | ||||||
|---|---|---|---|---|---|---|---|
| @ | √bbs.msgs
Conclusion: Seems to serve as an “if” keyword - but testing this theory in a traditional sense resulted in a syntax error. |
| Topic | Found in | ||||||
|---|---|---|---|---|---|---|---|
| [var$] | √bbs.msgs
Conclusion: Can serve as an empty variable check (null) |

























