Block Transfer
Chapter 10
1012
The purpose of block transfer data buffering is to allow the data to be
validated before it can be used. Data that is read from the block transfer
module and transferred to data table locations must be buffered. Data that
is written to the module need not be buffered because block transfer
modules perform this function internally.
Transferred data is buffered to ensure that both the transfer and the data are
valid. As an example, readings from an open-circuited temperature sensor
(invalid data) could have a valid transfer from an analog input module to
the data table. The processor examines data-valid and/or diagnostic bits
contained in the transferred data to determine whether or not the data is
valid. The block transfer done bit is set if the transfer is valid.
The data-valid and/or diagnostic bits differ for each block transfer module.
Some modules set one or both for the entire file of words transferred, while
others set a data-valid diagnostic bit in each word. Refer to the respective
user’s manual for the block transfer module to determine the correct usage
of the diagnostic and/or data valid bit(s).
One technique of buffering data is to store the transferred data in a
temporary buffer file. If the data in the buffer is valid, it is immediately
transferred to another file in the data table where it can be used. If invalid,
it is not transferred but written over in the next transfer.
Another technique uses only one file. The technique prevents invalid data
from being operated upon by preconditioning the rungs that would transfer
data out of a file one word at a time. Diagnostic and/or data-valid bits are
examined in these rungs.
Data can be moved from the buffer word-by-word using Get/Put transfers,
or the entire file can be moved at once using a FILE-TO-FILE MOVE
instruction. The choice depends on the kinds of diagnostic and/or
data-valid bits and the objectives of the user program. Generally, when one
diagnostic bit is contained in each word, a Get/Put transfer is used. When
one is set for the entire file, a FILE-TO-FILE MOVE instruction is used. In
either case, the diagnostic bits are examined as conditions for enabling the
file move or word transfer.
The example in Figure 10.7 shows the memory map and ladder diagram
rungs for buffering 3 words of data that are read from the block transfer
module. The data is read and buffered in the following sequence:
1. When rung 3 goes true, bit 014/07 (the block transfer enable bit) will
be turned on and block transfer will be requested. This latches on
storage bit 010/00 in rung 4.
10.8
Buffering Data
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com