1
0
mirror of https://github.com/RevCurtisP/C02.git synced 2024-11-26 13:49:21 +00:00
C02/include/x16.h02

38 lines
1.5 KiB
Plaintext
Raw Normal View History

2019-11-15 05:07:23 +00:00
/* C02 System Header file for Commander X16 */
2019-11-20 06:36:43 +00:00
/* Platform Specific Settings */
#pragma zeropage $70 $7F //Zero Page Free Space
2019-11-20 06:36:43 +00:00
2019-11-15 05:07:23 +00:00
/* Platform Specific Constants */
#define DELKEY $14 //Delete/Backspace Key (DEL)
#define ESCKEY $03 //Escape/Break Key (STOP)
#define RTNKEY $0D //Return/Enter Key (RETURN)
#define SYSBFL 128 //System Buffer Length
2019-11-15 05:07:23 +00:00
/* Standard Library Variables */
zeropage int srcptr, dstptr; //Source and Destination Pointer
zeropage int blkptr, stkptr; //Block and Stack Pointers
zeropage int tmpptr, usrptr; //Temporary and User Pointer
int stkbgn, stkend; //Stack Begin and End Address
int blkbgn, blkend; //Block Begin and End Address
char blklen, xmbank; //Block Segment Length, Ext Memory Bank
int xmaddr; //Extended Memory Address
char random, rdseed; //Pseudo-Random Number and Seed
char temp0, temp1, temp2, temp3; //Temporary Storage
char sysbfr[], sysbfp; //System String Buffer and Position
2019-11-15 05:07:23 +00:00
/* System Subroutines */
void delchr(); //Delete previous character
char getchr(); //Wait for character from Console
char getkey(); //Read ASCII character from Console
2019-11-15 05:07:23 +00:00
void newlin(); //Advance cursor to beginning of next line
char polkey(); //Poll Console for character
void prbyte(); //Print Accumulator as Hexadecimal number
2019-11-15 05:07:23 +00:00
void prhex(); //Print Low Nybble of Accumulator as Hex Digit
char putchr(); //Print ASCII character to Console
char putstr(); //Print ASCII string to Console
2019-11-15 05:07:23 +00:00
/* System Labels */
2019-11-15 05:07:23 +00:00
start: //Start of Code
exit: //Return to Operating System