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

6Ć35
bits of the device characteristics word in the SETUP portion of the
OPEN statement. For example, if you wanted to use a question mark
(hexadecimal 3F in ASCII) as the terminating character, you would
open the device as follows:
OPEN PORTA" AS FILE #2, SETUP=(OD3FH,1200)
The same rules apply to inputs not terminated by a carriage return
as to the disabled prompt input: no error messages and all data
must be entered at the same time.
Using a different terminator is more useful for those tasks
communicating to other devices or computers where the data
transmitted is not terminated with <CR> but another character. This
allows reading data from one of those devices without having to
accumulate the characters one at a time with a GET statement.
Refer to the OPEN statement description (6.8.1) for more information
on how the INPUT statement is used with the OPEN statement.
6.8.4
PRINT/PRINT USING Statements
The PRINT and PRINT USING statements are used to communicate
with I/O devices, such as a personal computer, or a line printer, or
another BASIC task. The OPEN statement is used to select to which I/O
port the PRINT/INPUT applies. Refer to the OPEN statement description
(6.8.1) for more information on how the PRINT statement is used with
the OPEN statement. The PRINT statement has the following basic
format (PRINT USING is defined separately in this section):
PRINT #logical_device_number, print_list
where:
logical_device_number =
logical number (1 to 255) assigned to a device
or channel during an OPEN statement. If no
device number is given, the default device is
PORTA on the Processor module on which this
tasks resides. Most application task I/O will be
handled through this default port.
print_list =
list of data items to be printed, such as:
DąInteger variables and integer expressions
DąReal variables and real expressions
DąBoolean variables and boolean expressions
DąString variables and string expressions
The optional parameter :FULL=n can be used to transfer control of
the program in the event that the channel is full. This option is only
allowed for channels and not devices. The parameter is added
immediately after the device number; n is the line number to which
to transfer control.
If the logical_device_number specifies a channel and not a device,
the number and type of items printed must match exactly the
channel template as specified in the OPEN CHANNEL statement.