Siemens SIMATIC S5 Series Manual page 79

Second serial interface of the programmable controller
Hide thumbs Also See for SIMATIC S5 Series:
Table of Contents

Advertisement

ASCII Driver
The FB1 example function block is used for printing out reports stored in the DB203 send data
block.
A printer output is initiated at every call of the function block and resetting of send initiation bit (KBS
bit 7). Here, the number output in the message text is incremented by 1 for every FB run.
The FB4 function block is used for conversion of the binary message number into ASCII
representation.
FB1 STL
NAME
:PRINT
:A
DB 203
:
:U
F
:JC = END
:
:L
FW 202
:ADD KF +1
:T
FW 202
:
:JC FB
NAME :DU>ASCII
DUAL :
FW 202
A-TH :
DW 14
A-ZE :
DW 15
:
:L
FW 204
:ADD KF +2
:T
FW 204
:
:JC FB
NAME :DU>ASCII
DUAL :
FW 204
A-TH :
DW 38
A-ZE :
DW 39
:
:AN
F
:S
F
:
END :BE
4-20
200.7
4
4
200.7
200.7
S5-95U, Second Serial Interface
Description
FB for printout of a message
Open send mailbox DB
KBS bit: "Send" (printing out)
Increment the number of the message
printout for the example by 1
Call of conversion FB
Source binary number
ASCII representation
ASCII representation Z/E (tens/units)
Data words to be updated in the send DB
Increment the number of the error text
for the example by 2
Call of conversion FB
Data words to be updated
in send DB
KBS bit 7
Initiate printout
T/H (thousands/hundreds)
EWA 4NEB 812 6095-02

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic s5-95u

Table of Contents