
PT-Basic Programming Manual Ver. 1.00 34/143
To activate KEY event trigger.
ON KEY(number%) GOSUB SubLabel | SubName
ON KEY(1) GOSUB F1
ON KEY(2) GOSUB F2
…
F1:
OFF KEY(1)
…
RETURN
F2:
OFF KEY(2)
…
RETURN
When a function key is pressed, a specific subroutine will be
executed.
number% is an integer variable in the range of 1 to 6,
indicating a function key of the keypad.
To activate MINUTE event trigger.
ON MINUTE GOSUB SubLabel | SubName
ON MINUTE GOSUB AMINUTE
…
AMINUTE:
CurrentTime$=TIME$
CurrentMin%=VAL(MID$(CurrentTime$,3,2))
IF CurrentMin%=30 THEN
BEEP(30,50,0,0)
WAIT(200)
END IF
RETURN
When the system time is on the minute, a specific subroutine
will be executed.
Commentaires sur ces manuels