Communications Mode
CP 523
7.7.1
Receiving Message Frames with Evaluation of the Specified Message
Frame Length
You can receive a fixed-length message frame from the CP with a Receive request.
Prerequisites
•
You must specify the fixed length in parameter block 7 when initializing the CP 523.
•
You must also make sure that the peripheral device sends only message frames of this length
to the CP.
Schematic for ”Receiving message frames with evaluation of the specified message frame
length”
1.
The CPU transfers the "Coordinate data transfer for receive message frame" request (A080
H
)
to word 0 of the transfer memory
2.
The CPU reads the coordination information from word 0 of the transfer memory. If there is no
message frame in the Receive mailbox (bit 7 in byte 1="0"), no message frame can be
received. The following information is available in the transfer memory together with the
coordination information:
- Word 2:
Length of the next message frame to be received (in bytes)
- Byte 6:
Number of message blocks in the next message frame to be received
- Byte 7:
Total number of message frames in the Receive buffer
3.
The CPU writes word 0 of the transfer memory.
The CP updates the transfer memory.
4.
The CPU reads the message frame from the transfer memory in message blocks of eight bytes.
The CPU reads the 1st message block from the transfer memory (eight bytes).
5.
The CPU writes word 0 of the transfer memory.
The CP updates the transfer memory.
6.
CPU reads further message blocks from the transfer memory.
7.
Steps 5 and 6 are repeated until the CPU has read the last message block.
7-76
EWA 4NEB 811 6044-02a