
Appendix G
BASIC Commands, Statements, and Functions
136
Item
Page
Function
Statement
Command
Description
ERL/ERR
Returns the error code and the line number where
the error has occurred
Spec
ERROR
Simulates an error and allows error codes to be
defined
Gen
FIX
Returns the integer part of a number
Arith
FOR...TO...
STEP
~
NEXT
Repeats a FOR to NEXT loop a specified number of
times
Gen
FRE
Returns the range of available memory
Spec
GOSUB
~
RETURN
Calls and executes the subroutine and returns to
the original program line with a “RETURN”
statement
Gen
GOTO
Branches to a specified line number
Gen
HEX$
Returns a string representing the hexadecimal value
of the decimal argument
Char
IF...THEN...
ELSE...GOTO
ELSE
Selects the statement to be executed or branch
destination as the result of an expression
Gen
INKEY$
Returns a character read from the keyboard
Spec
INPUT
Reads key input and assigns it to the specified
variable
Gen
INPUT$
Returns a character string read from the keyboard
and assigns it to the specified variable
Spec
INSTR
Searches for the first occurrence of a character
string and returns its position
Char
INT
Shortens an expression to a whole number
Arith
KEY
ON/OFF/STOP
Controls initiation, cancellation, and halting of key
input interrupt
Gen
LEFT$
Returns a character string of the specified number
of characters, beginning at the left of the string
Char
LEN
Returns the total number of characters in a
specified character string
Char
LET
Assigns the result of the expression to the variable
Gen
LINE INPUT
Reads one line of input from the keyboard and
assigns it to a character string variable
Gen
LIST/LLIST
Displays or prints a program
Comm
LOAD
Loads the program from the EEPROM or from a
port
Comm
LOC
Returns the number of characters in the input queue
waiting to be read
Spec
LOG
Returns the natural logarithm
Arith
MID$
Returns the specified number of characters starting
from the specified character position
Gen
Char
MON
Sets the terminal to monitor mode
Comm
MSET
Sets the address boundary for an assembly
program
Comm
NEW
Clears the program and all currently defined
variables
Comm
OCT$
Returns a string which represents the octal value of
the decimal argument
Char
ON COM
GOSUB
Defines the branch destination of a subroutine
invoked by an interrupt from a communication port
Gen
ON ERROR
GOTO
Causes branching to the specified line in the event
of an error
Gen
ON GOSUB
GOTO
Causes branching to the specified line when
“expression” is “true”
Gen
Содержание C500-ASC04
Страница 1: ...C500 ASC04 ASCII Unit Operation Manual Revised February 2001 ...
Страница 5: ...iv ...
Страница 7: ...vi ...