Siemens S5-100U User Manual page 311

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

Advertisement

S5-100U
The Block Entry Sequence and a Programming Example:
The following procedure is suggested:
1. Program FB1
2. Program OB21
3. Program OB22
4. Generate DB75
5. Transfer new data to the clock using the FORCE VAR programmer function (programmable
controller in the RUN mode) .
The respective programming examples are shown in Tables 12-10 to 12-14.
STL
FB 1
NAME:
CLOCK
L KH
4 4 4 B
T
RS 8
L KH
0 0 4 D
T
RS 9
L KH
0 C
0 0
T
RS 10
BE
EWA 4NEB 812 6120-02
- Defining system data for the integral real-time clock
- Calling up FB1 during a change from STOP to RUN
- Calling up FB1 when the programmable controller is switched on
- Storing clock data
Table 12-10. FB1 Program
Meaning
ASCII Code for the "D" character
Block number "75
D
Storing in system data word 8
DW0 is the start address for clock data
ASCII Code for the "M" Character
Storing in system data word 9
Flag word Number "12
ASCII Code is irrelevant
Storing in system data word 10
"
"
D
The Integral Real-Time Clock
Explanation
Clock data is
located in
DB75
beginning
with DW0
The status
word is
located in
FW12
12-17

Advertisement

Table of Contents
loading

Table of Contents