Siemens 020-011 用户手册

下载
页码 79
 
 
 
Industry Sector, IA&DT
 
 
 
 
SCE Training Curriculum 
Page 21 of 79  
To be used only in Educational and R&D  Facilities 
TIA Portal Module 020-011, Edition 04/2014
 
 
                                                 Unrestricted / © Siemens AG 2014. All Rights Reserved
 
SCE_EN _020-011_R1404_Startup Programming with SIMATIC S7-1500 
 
 
 
 
5.7 
What do logic operations look like in the PLC program? 
 
Logic operations are used to specify conditions for switching an output. 
In the PLC program, these conditions can be generated with the programming languages ladder 
diagram (LAD) or function block diagram (FBD). 
For reasons of clarity, we are using the FBD
A large number of logic operations is available that can be used in PLC programs.  
The AND as well as the OR logic operation and the NEGATION of an input are primarily used and will be 
briefly explained below using examples. 
 
Note: Information regarding additional logic operations is available quickly and clearly arranged in Online 
Help. 
 
5.7.1  AND Logic Operation 
 
Example of an AND logic operation: 
 
A lamp is to be lit when two switches are operated simultaneously as NO contact. 
 
Circuit diagram: 
 
 
 
 
 
 
 
Explanation: 
The lamp is lit exactly when both switches are operated;  i.e., if switches S1 and S2 are operated, lamp 
P1 is lit. 
 
24V 
S1 
S2 
P1