Siemens SIMATIC S5-115U User Manual page 468

Simatic s5 series cpu 941-7ub11 cpu 942-7ub11 cpu 943-7ub11 and cpu 943-7ub21 cpu 944-7ub11 and cpu 944-7ub21
Table of Contents

Advertisement

Communications Capabilities
OB1 STL
:
:AN
F
0.0
:L
KT 200.0
:SD
T
0
:A
T
0
:=
F
0.0
:
:JC
FB
1
NAME :DRUCKEN
:
:BE
Sample function block FB1 is used to print out message texts stored in send data block DB203.
Output to printer is initiated each time the function block is invoked and the send trigger bit
(CBS bit 7) reset.
Each time FB1 is invoked, the number output in the message text is incremented by 1. Function
block FB4 converts the message number from binary to ASCII.
FB1 STL
NAME
:DRUCKEN
:C
DB 203
:
:A
F
200.7
:JC =ENDE
:
:L
FW 202
:ADD KF +1
:T
FW 202
:
:JU
FB
4
NAME :DU>ASCII
DUAL :
FW 202
A-TH :
DW 21
A-ZE :
DW 22
:
:L
FW 204
:ADD KF +2
:T
FW 204
:
12-34
Description
CALL FB 1 EVERY 2 SECONDS
Description
MESSAGE OUTPUT FB
CALL SEND MAILBOX DB
CBS BIT: "SEND" (PRINT)
INCREMENT MESSAGE OUTPUT NUMBER
FOR EXAMPLE BY 1
CALL CONVERSION FB
SOURCE NUMBER (BINARY)
ASCII REPRES. T/H
(DATA WORDS TO BE UPDATED
ASCII REPRES. Z/E
IN SEND DB)
INCREMENT ERROR TEXT NUMBER
FOR EXAMPLE BY 2
S5-115U Manual
EWA 4NEB 811 6130-02b

Advertisement

Table of Contents
loading

Table of Contents