EasyManua.ls Logo

CipherLab 8 Series - Page 64

CipherLab 8 Series
263 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
52
CipherLab BASIC Programming Part I
ON COM … GOSUB …
Purpose To activate “COM Event Trigger”.
Syntax ON COM(N%) GOSUB SubName|SubLabel
Remarks “N%” is an integer variable, indicating the COM port.
“SubName|SubLabel” is the name or line label of a subroutine.
When data is received from the COM port, a specific subroutine will be
executed.
Example
ON COM(1) GOSUB HostCommand
…
HostCommand_1:
OFF COM(1)
…
ON COM(1) GOSUB HostCommand
RETURN
ON ESC GOSUB …
Purpose To activate “ESC Event Trigger”.
Syntax ON ESC GOSUB SubName|SubLabel
Remarks “SubName|SubLabel” is the name or line label of a subroutine.
When the ESC key is pressed, a specific subroutine will be executed.
Example
ON ESC GOSUB Key_Esc
…
Key_Esc:
OFF ESC
…
ON ESC GOSUB Key_Esc
RETURN

Table of Contents