Rockwell Automation 1771-DB BASIC MODULE User Manual

Page 216

Advertising
background image

Chapter
Call Routines 0–68

12

12 -26

Input Argument One
The first input argument is the source port number (PRT1 or PRT2) of the
BASIC module. A zero disables all previously active CALL 33
commands.

0 = disable CALL 33 for all active ports enabled by earlier CALL 33s
1 = PRT1 is source
2 = PRT2 is source

Input Argument Two
The second input argument is the maximum number of 8-bit characters you
want to copy from the BASIC serial port to the destination file.
The destination of your data (input argument four) determines the
maximum number of characters. These selections have a maximum
number of characters of:

PLC BTR = 126 (63 words)
Internal

string

=

string size – 3 (254 maximum characters)

- first character is the byte count value
- second character is the incremented transaction number
- last character is the terminating character

If the port has acquired less than the maximum when it receives a delimiter
character, it sends the packet including the delimiter to the BTR buffer.
The ladder logic can determine the amount of valid data transferred into
the BTR buffer from the byte count placed into the lower byte of BTR
word 1. If the data received exceeds the string length or BTR buffer size,
the remaining data is truncated.

Input Argument Three
The third input argument is the decimal value of the ASCII character
delimiter. You can choose any valid ASCII character. If you do not want a
delimiter, enter a null value (0 decimal). The data is transferred to the
destination buffer when the delimiter is received from the selected port
regardless of the number of characters received.

Input Argument Four
The fourth input argument is the selection of the BTR buffer with or
without the internal string or the internal string alone:

0

=

BTR

buffer

2 = BTR buffer and internal string
4 = internal string only

When transferring data to the internal string of the BASIC module, check
your transaction number for string updates because there is no indication
that data has been placed in the internal string. Your BASIC program must
check the transaction number to verify that the data was updated.

Advertising