Changes

Technical information about Locomotive BASIC

12 bytes removed, 11:33, 6 December 2012
/* BASIC tokens */
<br> Notes:
#*The &amp;ff code is used as a prefix for more keywords. See the table below for the list of keywords using this prefix. #*&amp;e2,&amp;e8 and &amp;e9 are not used #*&amp;7c ("|") is a character prefix used to identify a RSX command. e.g. "|DIR".
e.g. "|DIR". An RSX is encoded in a BASIC program using the following structure:
{| border="1"
|}
#*This token identifies a integer (16-bit) number. The two bytes following this token is the number, stored low byte then high byte. e.g. &amp;19,&amp;2d,&amp;00 represents the integer number "&amp;002d"="45". #*This token (&amp;0B) is changed at run-time to &amp;0D #*This token identifies a integer variable. 02,00,00,var name offset to number in program setup when program RUN. The variable name is stored directly, with bit 7 of the last character set. #*This token identifies a string variable. offset to string in program string stored AS IS with quotes around it. #*This token identifies a floating point number. Immediatly following the token are 5 bytes which define the number.
{| border="1"
|}
#*#This byte is the BASIC token identifying a floating point number #*#These 5 bytes define the floating point number. #*The space symbol is used as a command seperator #*Variable definitions: #**The variable definition has the following structure:
{| border="1"
#**All strings must be enclosed by double quote symbols (&amp;quot). This symbols define the start and end of the string value.
#**The string value can contain any symbol except the quote ("). i.e. 0-&amp;21, and &amp;23-&amp;ff can be used.
#*After running a program, Tokens of "1d" with 16-bit BASIC program line pointers are changed to token "1e" with the 16-bit memory address of the BASIC line number in memory.
<br> This table list the BASIC tokens with a &amp;ff prefix byte.
2,562
edits