Programming features: Difference between revisions

From Color 64 BBS Wiki
No edit summary
Tag: Reverted
No edit summary
Tag: Manual revert
 
(2 intermediate revisions by the same user not shown)
Line 3: Line 3:
Color 64 was written to be easily modified.  Several things have been designed into the system to make it easier for the programmer to modify the BBS system:  
Color 64 was written to be easily modified.  Several things have been designed into the system to make it easier for the programmer to modify the BBS system:  


The Color 64 ML adds many powerful commands and functions to BASIC's vocabulary, so that code can be designed as efficiently as possible. The ML code supporting this for versions 8.1 and beyond resides at $C000–$C3FF.
The Color 64 ML adds many powerful commands and functions to BASIC's vocabulary, so that code can be designed as efficiently as possible.  
 
Much work was done at looking into the specifics of the ML for 8.1 and 8.1a (both versions are the same), since this area has not been formally documented. Below are some key takeaways:
 
Specifically:
{| class="wikitable
|-
| Installing vectors into BASIC/KERNAL 
|
C01E BD 00 C1  LDA $C100,X
C021 9D 14 03  STA $0314,X
C024 BD 01 C1  LDA $C101,X
C027 9D 15 03  STA $0315,X
 
The code above copies vectors into $0314/$0315 (IRQ / BRK / interpreter hooks).
This is the token interception layer.
|-
| Returning control to BASIC after patching 
|  C041 4C 8D 08  JMP $088D
This code places the program back into BASIC’s main execution loop. This provides useful information on how ML Functions (@##), ML Variables (!##), and ML Commands (.##) are processed.
 
|-
| Interrupt-Hook
| $C32E
 
|-
| Entry Table
| $C300 -This contains the jump entries for various functions.
C300 JMP $C498
C303 JMP $C461
C306 JMP $C3CF
C309 JMP $C38F
...
C310 JMP $C4EF
C313 JMP $C509
C316 JMP $C4B5
C319 JMP $C4C3
C31C JMP $C4DE
C31F JMP $C4E6
|}


The overlays were designed uniformly, so that all overlays have the same basic "skeleton" of essential routines.   
The overlays were designed uniformly, so that all overlays have the same basic "skeleton" of essential routines.   

Latest revision as of 13:47, 14 December 2025


Color 64 was written to be easily modified. Several things have been designed into the system to make it easier for the programmer to modify the BBS system:

The Color 64 ML adds many powerful commands and functions to BASIC's vocabulary, so that code can be designed as efficiently as possible.

The overlays were designed uniformly, so that all overlays have the same basic "skeleton" of essential routines.

The overlays were left "open ended", which means that you can easily install one of the many pre-written modules into your overlays.


The Enhanced BASIC Language

Color 64 offers a set of powerful new additions to the BASIC programming language. These additions only work while the BBS program is running, as it is a modification of BASIC made by the ML associated with the BBS program.

The descriptions of the new commands are presented in the following format: Items enclosed in angle brackets, "<" and ">", are descriptions of data items that you must provide. Items enclosed in square brackets, "[" and “]", are optional items.