19.08.2013 Views

Safety Integrated - Industry - Siemens

Safety Integrated - Industry - Siemens

Safety Integrated - Industry - Siemens

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The sample code with the given configurations enables the<br />

following:<br />

■ Resetting a failsafe digital output after actuating the emergency<br />

stop push button<br />

■ Renewed setting (= start of the application) of the failsafe<br />

digital output requires the following:<br />

1. User acknowledgement (does not automatically start<br />

the application)<br />

2. Starting the application (only possible in case of previous<br />

acknowledgement)<br />

Program procedure<br />

FC "START_AND_STOP" (FC10)<br />

The (non-failsafe) FC "START_AND_STOP" (FC 10) is called<br />

from OB 1 (see following figure).<br />

...<br />

"START"<br />

"STOP"<br />

EN<br />

START<br />

STOP<br />

"START_AND_STOP"<br />

Parameter Adress Explanation<br />

COND<br />

ENO<br />

"COND"<br />

START E 0.1 Push button (NO) for the start requirement.<br />

STOP M 90.5 Dummy. If the operation related stop<br />

is to be implemented, replace the<br />

memory bit by an input Ex.y.<br />

COND M 90.0 Saves the information start/ stop of<br />

the "machine".<br />

The information of the memory bit "COND" is read as memory<br />

bit COND1 in the safety program. This allocation occurs in the<br />

cyclic interrupt OB35 for the following reason:<br />

When reading data, which may be changed by the standard<br />

user program or an operation control and monitoring system<br />

during running of an F runtime group, from the standard user<br />

program (memory bits or PAE of standard I/O), in the safety<br />

program, it is necessary to use separate memory bits (here<br />

COND1). Data from the standard user program have to be<br />

written to these memory bits immediately before calling the F<br />

runtime group. Only these memory bits may then be accessed<br />

in the safety program.<br />

G_FB_XX_078<br />

In this example it has already been implemented. Generally,<br />

however, the following applies:<br />

Note<br />

If the above section is not observed the F CPU may go to<br />

STOP mode.<br />

The FC "START_AND_STOP" (FC 10) in the following figure<br />

sets/resets #COND whose signal status ("0" or "1") starts or<br />

stops the "machine" in the failsafe program. #COND can only<br />

become "1" if the emergency stop button has been unlocked<br />

and acknowledged prior to the start (occurs in the safety program).<br />

This is ensured by the "Instanz_FB1".EN_ESTP bit from<br />

the instance data block DB 1 of FB 1 (from the safety program).<br />

This bit must have been set for a possible start. If this<br />

bit is "0" the "1" signal lies at the R entry of the flipflop, which<br />

makes the output Q always "0", even if with #START the S entry<br />

receives the "1" signal (resetting has priority with the used<br />

flipflop).<br />

#START<br />

#STOP<br />

"INSTANZ_<br />

FB1".<br />

EN_ESTP<br />

"P" "SR"<br />

P<br />

SR<br />

>=1<br />

#COND<br />

=<br />

The failsafe program has the following program sequence:<br />

F-Call<br />

(FC1)<br />

Functional Example No. AS-FE-I-001-V10-EN 177<br />

S<br />

FC"COORDINATION"<br />

(FC2)<br />

R Q<br />

FB"ESTOP"<br />

(FB1,DB1)<br />

FC"REINTEGRATION"<br />

(FC3)<br />

G_FB_XX_079<br />

G_FB_XX_080<br />

Ex. No.<br />

1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!