26.10.2012 Views

Statement List (STL) - DCE FEL ČVUT v Praze

Statement List (STL) - DCE FEL ČVUT v Praze

Statement List (STL) - DCE FEL ČVUT v Praze

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.

<strong>Statement</strong> <strong>List</strong> that Activates the Indicator Lamps on the Display Panel<br />

Programming Examples<br />

<strong>STL</strong> Explanation<br />

A I 0.0 //Each pulse generated by photoelectric barrier 1<br />

CU C1 //increases the count value of counter C 1 by one, thereby counting the number<br />

of packages going into the storage area.<br />

//<br />

A I 0.1 //Each pulse generated by photoelectric barrier 2<br />

CD C1 //decreases the count value of counter C 1 by one, thereby counting the<br />

packages that leave the storage area.<br />

//<br />

AN C1 //If the count value is 0,<br />

= Q 4.0 //the indicator lamp for "Storage area empty" comes on.<br />

//<br />

A C1 //If the count value is not 0,<br />

= A 4.1 //the indicator lamp for "Storage area not empty" comes on.<br />

//<br />

L 50<br />

L C1<br />

=I //If the count value is greater than or equal to 90,<br />

= Q 4.3 //the indicator lamp for "Storage area 90% full" comes on.<br />

//<br />

L Z1<br />

L 100<br />

>=I //If the count value is greater than or equal to 100,<br />

= Q 4.4 //the indicator lamp for "Storage area filled to capacity" comes on. (You could<br />

also use output Q 4.4 to lock conveyor belt 1.)<br />

<strong>Statement</strong> <strong>List</strong> (<strong>STL</strong>) for S7-300 and S7-400 Programming<br />

A5E00706960-01 B-11

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

Saved successfully!

Ooh no, something went wrong!