Rockwell Automation 1771-DB BASIC MODULE User Manual

Page 219

Advertising
background image

Chapter
Call Routines 0–68

12

12 -29

Important: This call requires the BASIC module jumper JW5 to be in 16
point mode (page 1 -7).

Use CALL 34 to transfer data from the BTW buffer file directly to the
BASIC module serial port and/or to a string within the BASIC module.

This call is useful for writing to a remote display device (operator
interface) directly from the PLC processor or an internal string. Once you
set up and enable this operation it is performed transparently in the
background while the BASIC module executes a BASIC program in the
foreground.

You can transfer the data low byte first, then high byte or high byte first,
then low byte to the BASIC module port. You can also store the data in a
string for the BASIC program to access. The byte swap selection (low
byte first, then high byte, or high byte first, then low byte) of the last
CALL 34 or CALL 33 you executed determines the data packing method
for all ports CALL 34 enables.

The low byte of the first word of the source file contains the character
count (byte count) of the data you want to transfer. If the byte count is
larger than the file, you can only transfer the maximum number of bytes
within the file. You do not use the high byte of the first word.

Execute CALL 34 to set up the data transfer parameters. After you
execute the call, the BASIC module gets data from the BTW buffer and
transfers it to port PRT1, port PRT2, or an internal string.

1.

The ladder logic program of the PLC processor builds the data buffer.
The ladder logic then determines the byte count of the file you want
to transfer and places it into the lower byte of the BTW buffer word 1
to be transferred. This word plus the data comprise the data file to be
transferred.

BASIC Module

PRT2

PRT1

DATA BUFFER

BTW Buffer

BYTE
COUNT

Reserved

CALL 34: Transfer Data
from the BTW buffer to
PRT1 or PRT2

Tip

Advertising