EasyManua.ls Logo

Siemens SIMATIC S7-400H - Example of STL

Siemens SIMATIC S7-400H
336 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Using I/O on the S7-400H
7-39
Automation System S7-400H Fault-tolerant Systems
A5E00068197-07
Example of STL
The requisite sections of the user program (OB1, OB 122) are listed below.
Table 7-6 OB 1
STL Explanation
NOP 0;
SET;
R VERSUCH2; //Initialization
A BGA; //Read module A first?
JCN WBGB; //If No, continue with module B
WBGA: SET;
R PZF_BIT; //Delete PZF bit
L PED 8; //Read CPU 0
U PZF_BIT; //Was PZF detected in OB 122?
SPBN PZOK; //If no, process access OK
U VERSUCH2; //Was this access the second attempt?
SPB WBG0; //If yes, use substitute value
SET;
R BGA; //Do not read module A first any more
//in future
S VERSUCH2;
WBGB: SET;
R PZF_BIT; //Delete PZF bit
L PED 12; //Read CPU 1
U PZF_BIT; //Was PZF detected in OB 122?
SPBN PZOK; //If no, process access OK
U VERSUCH2; //Was this access the second attempt?
SPB WBG0; //If yes, use substitute value
SET;
S BGA; //Read module A first again in future
S VERSUCH2;
JU WBGA;
WBG0: L ERSATZ; //Substitute value
PZOK: //The value to be used is in Accumulator1

Table of Contents

Other manuals for Siemens SIMATIC S7-400H

Related product manuals