Receiving Data - Siemens S5-100U User Manual

Simatic s5 programmable controller
Hide thumbs Also See for S5-100U:
Table of Contents

Advertisement

S5-100U
The control program for sending data should be structured as follows:
1. Check bit 7 in the KBS to see if data is currently being sent.
- If the programmable controller is sending data, bit 7 is set. During this phase, the Send
Mailbox can not be modified and no transmission can be started.
2. When bit 7 in the KBS has been reset, you can start the transmission by setting bit 7.
3. When bit 7 has been reset by the operating system after data has been sent, you can evaluate
possible errors.
You achieve the following by setting bit 4 in the KBS (express transmission):
The sending programmable controller treats this message preferentially (possibly by overwriting
a telegram not yet sent).
The receiver treats the message as an express transmission.
In case of an error, the operating system sets bit 0 of the KBS. The error message is not valid until
bit 7 has been reset in the KBS.

13.3.2 Receiving Data

The prerequisites for receiving data are as follows:
The parameters for the location of the Receive Mailbox and the Coordination Byte Receive (KBE)
(see section 13.2.2) have been set in DB1. Figure 13-6 shows you which information has to be
stored in what part of the Receive Mailbox.
Example:
Receive Mailbox in the flag area
(beginning with flag byte 1)
Flag Byte 1
Length of "net data" (in
bytes)
Flag Byte 2
Source slave number
Flag Byte 3
Data ("net data")
*
Number of the sender:
1 to 30 = Slave
EWA 4NEB 812 6120-02
*
0 = Master
Figure 13-6. Structure of the Receive Mailbox
Connecting the S5-100U to SINEC L1
Example:
Receive Mailbox in a data block
(beginning with data word 1)
DL
DW1
Length of the "net
data"
DW2
1st data byte
DW3
3rd data byte
DR
Source slave
*
number
2nd data byte
4th data byte
13-9

Advertisement

Table of Contents
loading

Table of Contents