Technical data
Linkage with PLC
148 VIPA GmbH CP486 ⋅ 00/14
6.4.2.3 Read a Block from the PC
With this function a whole block of data can be read from the PC. The function is just starting the
job, and does not wait until the PC is executing it, but returns immediately to where it was called.
Therefore the data can be read not before the function 'status call' was executed (see there).
Register
high In low Out
AX $21 typ status
BX size bst
CX adr
DX len
typ element area (type) of data for single element in the PC (DB, MB, ...)
size data size of block data (ident. whether single bytes are to be exchanged)
0F(hex) data block of bytes (no exchange)
1F(hex) data block of words (exchange of high- and low-byte)
2F(hex) data block of doublewords (exchange of all 4 bytes)
bst module number, is to be set for element areas (type) DB, DX , FX ...
if element area (type) is absolute, then here are high-order bits of adr.
adr initial address in the area
len number of data in words !! (also if size is byte or doubleword)
status < 0 error number because of error
= 0 job number to call status
Note:
For reasons of executing an automatical adjustment of data during the transmission, the type of the
data in a block (bytes, words, doublewords) has to be specified. One block can only contain data of
the same type. Concernig words and doublewords for every single data an exchange of the bytes is
executed correspondingly.
This function does not return data! If the job status is 'finished without error', the data can be passed
by calling the function status call.
A block read job can only be started, if bank 2 is empty, that means, no variable read jobs and no
block read job may be in processing status.
To enable, that a finished reading job will not be overwritten with a new job before data are passed,
the job is blocked. After starting a job, its status is to be checked as long as the job is finished with
or without error. If the status of the job is 'finished without error', data will be copied to the AT with
the address specified. If no status call is executed, the job remains blocked, and possibly no further
read jobs can be started.