
51
Program Example:
10
WAIT “10.0”, 100
20
PC READ “3I4”; A, B, C,
30
PRINT A, B, C
40
END
100
PRINT “PC ERR”
110
GOTO 40
Program Remarks:
This example will display the message “PC ERR” if the PC READ statement is
not executed within 10 seconds.
4-2-4
Device Control Statements
This section describes statements that control hardware and communications.
CLOSE Statement
Purpose:
To close a port
Format:
CLOSE [#<port>]
<port> is an integer (1 or 2).
Remarks:
If the port number is omitted, both ports will be closed.
Once the port has been closed, it cannot be used for data transfer until it is
opened again.
Be sure to execute the CLOSE statement to correctly end the output process.
CLOSE dumps any data remaining in the buffer from output operations. It does
not dump data from input operations.
To turn OFF the error indicators at Port 1 and Port 2 or error bits that are ON due
to a transmission error or reception buffer overflow, execute the CLOSE state-
ment.
The END statement and the NEW command automatically close the ports, but
the STOP statement does not.
CLS Statement
Purpose:
To clear the screen
Format:
CLS [#<port>]
<port> is an integer (1 or 2).
Remarks:
This statement clears the screen and moves the cursor to the home position. If
the port number is omitted, port 1 is assumed.
OPEN Statement
Purpose:
To allow input/output operations to take place through the speci-
fied port
Format:
OPEN #<port>, “<device name>:[(<com spec. or vsl>)]”
<port> is an integer (1 or 2).
<device name> identifies the device.
<com spec> stands for the communication specifications.
<vsl> stands for valid signal line.
Examples: OPEN #1,“KYBD:”
OPEN #2,“COMU:(14)”
Commands, Statements, and Functions
Summary of Contents for C500-ASC04
Page 1: ...C500 ASC04 ASCII Unit Operation Manual Revised February 2001 ...
Page 5: ...iv ...
Page 7: ...vi ...