Rockwell Automation 57C610 Enhanced Basic Language, AutoMax User Manual
Page 74

6Ć34
system will prompt again, indicating that it is waiting for more data.
The system will also prompt again if the operator enters just a
expected data is received. Note that the receive FIFO queue will
accept a maximum of 64 bytes. If more than 64 bytes are
received without the queue being emptied, the additional data is
discarded.
In the following example, 3 integer fields are expected by the INPUT
routine, but only 2 are entered the first time. BASIC prompts again
for the third number to be entered. The fields can be separated with
commas or spaces if the prompt is off. If the prompt is on, each field
is separated with
In the task:
10 INPUT A%, B%, C%
On the display screen:
?34,56
?46
?
If you make a mistake while entering data, use the backspace key to
back up the cursor and enter the correct data. Enter
cancel any data on the line. If the data entered is totally incorrect,
enter
of the variables in the INPUT statement will be updated and
execution will continue with the next statement after the INPUT.
When the prompt is enabled, certain error messages are displayed
to the user if his input data is invalid. For example, if the statement is
INPUT A% and the value entered is either out of range (not +32767
to -32768) or of the wrong type (string instead of integer), the
system will prompt:
>>>>>INVALID DATA TYPE Ć INPUT AGAIN<<<<<<
and reĆprompt for data that will fit into a single integer (+32767 to
-32768).
You can enable or disable the input prompt by writing to the variable
_PROMPT@". This symbol is automatically allocated as a local
variable when the task is created. At powerĆup, it has the value
TRUE (print a prompt character during input). If the value of this
variable is changed to FALSE, the prompt is disabled.
You may find it desirable to disable the prompt when you are
soliciting input from a personal computer and do not wish to have
the prompt character appear on the display. However, when the
prompt is disabled, any input errors that occur will result in a
runĆtime error. Program execution will continue with the next
statement. Therefore, when you disable the prompt, you should use
the ON ERROR GOTO statement to initiate an errorĆhandling routine.
The following are valid INPUT statements:
20 INPUT #1,A%,B%
30 INPUT A%,B%
40ăINPUT #3:FULL=80, C%
It is possible to define a character other than carriage return
(
done by loading the ASCII value of the character into the lower 8