Вы находитесь на странице: 1из 144

s

Getting Started CPU 31x:


Commissioning
Getting Started CPU 31xC:
SIMATIC Commissioning
First Steps in Commissioning
CPU 31xC: Positioning with
Automation System S7-300 analog output

Getting Started Collection First Steps in Commissioning


CPU 31xC: Positioning with Digital
Outputs
Getting Started - Commissioning a
CPU 31xC: Counting
Getting Started - Commissioning a
CPU 31xC: Point-to-point link
Getting Started - Commissioning a
CPU 31xC: Closed-loop control
CPU 315-2 PN/DP, 317-2 PN/DP,
319-3 PN/DP: Configuring the
PROFINET interface

This manual is part of the documentation


package with the order number:
6ES7398-8FA10-8BA0

06/2008
A5E00123662-07
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to
prevent damage to property. The notices referring to your personal safety are highlighted in the manual
by a safety alert symbol, notices referring to property damage only have no safety alert symbol. The
notices shown below are graded according to the degree of danger.

Danger
! indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
! indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
! with a safety alert symbol indicates that minor personal injury can result if proper precautions are not
taken.

Caution
without a safety alert symbol indicates that property damage can result if proper precautions are not
taken.

Notice
indicates that an unintended result or situation can occur if the corresponding notice is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of
danger will be used. A notice warning of injury to persons with a safety alert symbol may also include a
warning relating to property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning
and operation of a device/system may only be performed by qualified personnel. Within the context of
the safety notices in this documentation qualified persons are defined as persons who are authorized to
commission, ground and label devices, systems and circuits in accordance with established safety
practices and standards.

Prescribed Usage
Note the following:

Warning
! This device and its components may only be used for the applications described in the catalog or the
technical description, and only in connection with devices or components from other manufacturers
which have been approved or recommended by Siemens.
Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG.
The remaining trademarks in this publication may be trademarks whose use by third parties for their
own purposes could violate the rights of the owner.
Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and
software described. Since variance cannot be precluded entirely, we cannot guarantee full consistency.
However, the information in this publication is reviewed regularly and any necessary corrections are
included in subsequent editions.

Siemens AG A5E00123662-07
Copyright © Siemens AG 2008
Automation and Drives
06/2008 Technical data subject to change
Postfach 4848
90437 NÜRNBERG
GERMANY
Introduction 1

Preparation 2

Units 3
SIMATIC
Further Information 4
S7-300
S7-300 Automation System: Getting
Started CPU 31x: Commissioning

Getting Started

06/2008
A5E00164278-04
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

DANGER
indicates that death or severe personal injury will result if proper precautions are not taken.

WARNING
indicates that death or severe personal injury may result if proper precautions are not taken.

CAUTION
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

CAUTION
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

NOTICE
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

WARNING
This device may only be used for the applications described in the catalog or the technical description and only
in connection with devices or components from other manufacturers which have been approved or
recommended by Siemens. Correct, reliable operation of the product requires proper transport, storage,
positioning and assembly as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG A5E00164278-04 Copyright © Siemens AG 2008.


Industry Sector Ⓟ 07/2008 Technical data subject to change
Postfach 48 48
90327 NÜRNBERG
GERMANY
Table of contents
1 Introduction................................................................................................................................................ 5
2 Preparation ................................................................................................................................................ 7
3 Units ........................................................................................................................................................ 11
3.1 1. Step: Installing and Grounding the Rail ...................................................................................11
3.2 2. Step: Wiring modules...............................................................................................................13
3.3 3. Step: Commissioning the Hardware ........................................................................................14
3.4 4. Step: Configuring hardware in HW-Configuration of STEP 7 ..................................................15
3.5 5. Step: Programming a circuit.....................................................................................................17
3.6 6. Step: Test Run .........................................................................................................................18
4 Further Information .................................................................................................................................. 19

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 3
Table of contents

S7-300 Automation System: Getting Started CPU 31x: Commissioning


4 Getting Started, 06/2008, A5E00164278-04
Introduction 1
Contents of this Getting Started Manual
In this manual, we will use a practical example to guide you through the steps required to
create a functioning application. While working through the example, you will learn the basic
hardware and software functions associated with your CPU.
This process will take one to two hours, depending on your experience.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 5
Introduction

S7-300 Automation System: Getting Started CPU 31x: Commissioning


6 Getting Started, 06/2008, A5E00164278-04
Preparation 2
Applicability
This guide applies to the following CPUs:

Requirements
● You need to have a basic understanding of electronics/electrical engineering, and have
experience in working with Microsoft® Windows™.

WARNING
When using the S7-300 as a component of plants and systems, you may be required to
follow certain rules and regulations according to the specific application. Please note the
applicable safety and accident prevention regulations, such as IEC 204 (emergency
stop systems).
Non-compliance with these regulations can result in serious injury and damage to both
machinery and equipment.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 7
Preparation

Material and tools required

Quantity Item Order number (Siemens)


1 Mounting rail e.g. 6ES7 390-1AE80-0AA0
1 Power supply (PS) module e.g. 6ES7 307-1EA00-0AA0
1 CPU 31x, e.g. CPU 312 e.g. 6ES7 312-1AE13-0AB0
1 SIMATIC Micro Memory Card e. g. 6ES7 953-8Lx20-0AA0
Note:
The SIMATIC Micro Memory Card is essential for the operation of certain
CPUs (see Applicability).
1 Digital input module (DI) with bus connector e.g. 6ES7 321-1BH02-0AA0
1 Digital output module (DO) with bus connector e.g. 6ES7 322-1BH01-0AA0
2 Multipin front connector with screw-type contacts e.g. 6ES7 392-1AM00-0AA0
1 • Programming device (PG) with MPI interface and STEP 7 software Depends on configuration
as of V5.2 + SP2 installed and PG cable or
• PC with suitable interface card
Various M6 screws and nuts (length depends on installation location) with commonly available
suitable screwdriver / wrench
1 Screwdriver with 3.5 mmblade commonly available
1 Screwdriver with 4.5 mm blade commonly available
1 Side cutter and cable stripper commonly available
1 Crimp tool commonly available
Xm Cable with 10 mm2 cross-section for grounding the rail and suitable commonly available
cable lug for M6 screw. Length of cable depends on local requirements.
Approx. Flexible cable with 1 mm2 cross-section and suitable ferrules with commonly available
2m insulated collar, length 6 mm
Xm 3-core flexible power cable (AC 230/120 V) with shockproof plug; length commonly available
dependant on local requirements, with suitable ferrules and insulating
collar.
2 Single--pole ON button (24 V) commonly available

S7-300 Automation System: Getting Started CPU 31x: Commissioning


8 Getting Started, 06/2008, A5E00164278-04
Preparation

Layout of the example

4 5 6
3

36 &38 ', '2

8
Figure 2-1 Sample layout (certain details of the CPUs may differ from the above illustration)

(1) Mounting rail


(2) Power supply ON / OFF
(3) For setting the line voltage
(4) LEDs
(5) Memory Card/SIMATIC Micro Memory Card
(6) Mode selector switch
(7) PG cable for connecting to the MPI interface
(8) Programming device (PG) with STEP 7 software

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 9
Preparation

1
2

/ 3
0

/
4
0

'&9
/
0 /
0

6 5
99

Figure 2-2 Wiring the power supply and CPU (front cover open)

(1) Power supply (PS) module


(2) CPU
(3) MPI interface for connecting to the PG
(4) Removable power supply connection
(5) Connecting cables between the PS and CPU
(6) Strain relief

Functionality of the example


The output cannot switch (i.e. so that the diode on the output module lights up) until the
buttons are pressed.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


10 Getting Started, 06/2008, A5E00164278-04
Units 3
3.1 1. Step: Installing and Grounding the Rail

Install and ground the mounting rail


1. Screw on the mounting rail (screw size: M6). Make sure to maintain a minimum clearance
of 40 mm above and below the mounting rail.
When mounting it on a grounded metallic panel or on a grounded device mounting panel
made of steel sheet, make sure you have a low impedance connection between the
mounting rail and the mounting surface.
2. Connect the rail to the protective conductor. An M6 protective conductor screw is
provided on the mounting rail for this purpose.
Stipulated cross-section of the cable connection to the protective conductor: at least
10 mm2.

1.

2.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 11
Units
3.1 1. Step: Installing and Grounding the Rail

Installing modules on the mounting rail


1. First of all, insert the power supply module. Slide it to the left until it meets the grounding
screw of the mounting rail and then screw it on.
2. To connect further modules, insert a bus connector into the CPU (see drawing section)

3. Hang in the CPU (1).


4. Slide it up to the left module (2).
5. You can then swing it down (3).

2 1

6. Screw-tighten the modules on the mounting rail.


7. You need to use a CPU with a SIMATIC Micro Memory Card. Insert this into the
receptacle.
8. You also need to install digital input and output modules to the right of the CPU. To do
this, repeat steps 1 to 6.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


12 Getting Started, 06/2008, A5E00164278-04
Units
3.2 2. Step: Wiring modules

3.2 2. Step: Wiring modules

WARNING
You may come into contact with live wires that are connected to the power supply. Make
sure that the S7-300 is completely disconnected before you start wiring.

Wiring the Power Supply and the CPU


1. Open the front panels of the power supply and the CPU.
2. Detach the strain relief clip from the power supply.
3. Strip the flexible power cable, crimp on the ferrules and connect them to the power
supply. (Blue to terminal M, black to terminal L1, protective conductor to terminal PE)
4. Screw the strain relief clamp in place.
5. Next, wire the power supply to the CPU. Use flexible cable with a conductor cross-section
of 1 mm2.
Strip the ends to approx. 6 mm and crimp on the ferrules. Connect terminals L+ and M on
the power supply to those on the CPU.
6. Check that the line voltage selector switch is set to the correct line voltage.
The power supply is set at the factory to a line voltage of AC 230 V. To label a front
connector, follow the steps outlined below: To change the voltage, remove the protective
cap with a screwdriver, set the switch to the required line voltage and replace the
protective cap.

Wiring the Digital Input and Output Modules


1. Open the front panels of the digital input and output modules.
2. Push front connectors into the DI and the DO until they snap into position. The front
connector still protrudes from the module in this wiring position, and is not yet connected
to the module.
3. Cut around 10 wires (1mm2) to length (20 cm), and attach ferrules to the ends.
4. Wire the front connector for the digital input module as follows:
– Terminal L+ to terminal L+ on the power supply; terminal M to terminal M on the power
supply
– Terminal 3 to the first connection of button 1
– Terminal 4: with the first connection to button 2
Connect the two unassigned connections on buttons 1 and 2 to L+ on the power supply.
5. Wire the front connector for the digital output module as follows:
– Terminal L+ to terminal L+ on the power supply
– Terminal M to terminal M on the power supply
6. Lead the wires downwards out of the front connectors.
7. Press the release button on the front connector at the top of the module. At the same
time, push the front connector into the module until the release button snaps back into its
initial position.

Note
Please note: If you are using 40-pin front connectors, they must also be fixed using the
fixing screw in the center of the front connector.

8. Close the front panels of the digital input and output modules and the power supply.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 13
Units
3.3 3. Step: Commissioning the Hardware

3.3 3. Step: Commissioning the Hardware

Procedure
1. Use the PG cable to connect the programming device to the CPU. When using a cable
with PROFIBUS connectors, remember to switch on the integrated terminating resistors.
Close the front panel cover of the CPU, then set the mode selector switch on the CPU to
STOP.
2. Connect mains, then switch on the power supply module.
The DC24V LED on the power supply is lit.
All the LEDs on the CPU light up briefly; the SF-LED and the DC5V-LED stay lit. The
STOP-LED then flashes slowly to indicate a CPU memory reset.
3. Depending on the type of CPU, you will need to insert either the SIMATIC Micro Memory
Card or the backup battery into your CPU.
4. Perform a CPU memory reset:
– Turn the mode switch to MRES. Hold it in this position until the STOP LED lights up
for the second time and then remains lit. Then release it.
– You then have 3 seconds in which to turn the mode switch back to MRES. The STOP
LED begins to flash rapidly and the CPU performs a reset. You can now release the
mode switch. The CPU has completed the memory reset when the STOP LED
remains permanently lit again.
5. Start your programming device, then run SIMATIC Manager from your Windows Desktop.
A window opens with SIMATIC Manager.
6. Select button 1.
The LED for the first input lights up.
7. Select button 2.
The LED for the second input lights up.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


14 Getting Started, 06/2008, A5E00164278-04
Units
3.4 4. Step: Configuring hardware in HW-Configuration of STEP 7

3.4 4. Step: Configuring hardware in HW-Configuration of STEP 7

Create a new project in STEP 7:


1. Select the File > New... menu command.
Enter a name for your project and click on OK to confirm.
A new project is created

Add a new S7-300 station


1. Select the Insert > Station > SIMATIC 300 Station menu command.
The SIMATIC 300 (1) icon in the right-hand part of the window is highlighted.

Add a rail
1. In the right-hand part of the window, double-click first on the SIMATIC 300(1) icon and
then on the Hardware icon.
The hardware configuration editor (HW Config) opens.
2. You can insert your hardware components from the hardware catalog in the left-hand part
of the window.
If no catalog is displayed, activate the catalog using the View > Catalog menu command.
In the hardware catalog, navigate to Rack-300 via SIMATIC 300. Copy the rail by
dragging and dropping it in the right-hand part of the window.
The rail is inserted in the right-hand part of the window

Add the power supply:


1. In the hardware catalog, navigate to PS-300. Drag your power supply and drop it into slot
1 on the rail.

Note
Note: You can click on the power supply to display its order number. The order number
then appears in the box beneath the catalog.

● The power supply module is inserted into slot 1.

Add the CPU:


1. In the hardware catalog, navigate to CPU-300. Drag your CPU and drop it into slot 2 on
the rail.
The CPU is inserted into slot 2.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 15
Units
3.4 4. Step: Configuring hardware in HW-Configuration of STEP 7

Add the digital input and output modules:


1. In the hardware catalog, navigate to DI-300 via SM-300 and select your digital input
module.
Drag the digital input module to the rail and drop it into slot 4.
The digital input module is inserted into slot 4.
2. In the hardware catalog, navigate to DO-300 via SM-300 and select your digital output
module.
Drag the digital output module to the rail and drop it into slot 5.
The digital output module is inserted into slot 5.

Save and compile your configuration:


1. Select the Save and Compile command from the Station menu.
The hardware configuration is compiled and saved.
2. Close the editor.
The editor is closed.
The CPU now appears in the station in SIMATIC Manager.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


16 Getting Started, 06/2008, A5E00164278-04
Units
3.5 5. Step: Programming a circuit

3.5 5. Step: Programming a circuit

Procedure
1. In the right-hand part of the window, first double-click on the CPU icon, then on the S7
program(1) icon, then on the Blocks icon and finally on the OB1 icon.
The “Properties” dialog for OB1 is displayed.
2. From the properties for the organizational block, select the ladder diagram development
language. Click on OK to confirm.
The program editor opens.
3. Carefully click on the horizontal line representing the current path.
The line is highlighted.
4. On the toolbar, click twice on the --||-- icon (normally-open contact) and then once on the
–( ) icon (coil).
The icons are inserted into the current path.
5. Click on the red question mark for the left-hand normally- open contact in the current
path.
The normally-open contact is highlighted and the question mark is replaced with a text
input box containing the cursor.
6. Enter E124.1 and press Return.
The left-hand normally-open contact is now called I124.1.
7. Label the right button in the same way with I124.2 and the coil with Q124.0.

8. set the File > Close menu command to close the editor, and click Yes when you are
prompted to save.
The editor is closed and OB 1 is saved.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 17
Units
3.6 6. Step: Test Run

3.6 6. Step: Test Run

Procedure
1. Use the SIMATIC 300 station and your CPU to browse to the S7 program.
In SIMATIC Manager, click on Blocks in the right-hand part of the window.
Blocks will now be highlighted.
2. Select "Download" from the "Target system" menu to transfer the program and hardware
configuration to the CPU. Confirm all windows with Yes.
The program and configuration are downloaded from the programming device to the
CPU. The program is now stored on the Micro Memory Card (in the load memory), where
it is unaffected by power failures and resets.
3. Set the CPU's mode switch to RUN.
The STOP LED is switched off. The RUN LED starts to flash and then assumes a
continuous signal.
4. Press each of the buttons alternately.
The LEDs of each input will light up in turn.
5. Press both buttons simultaneously.
The LEDs of both inputs will light up at the same time.
The LED for the first output lights up.
This equates to connection of a connected final controlling element or display.

S7-300 Automation System: Getting Started CPU 31x: Commissioning


18 Getting Started, 06/2008, A5E00164278-04
Further Information 4
Diagnostics/Correction of Errors
Wrong operation, faulty wiring or a faulty hardware configuration may cause errors which the
CPU indicates with the SF group error LED after a CPU memory reset.
For information on how to analyze such errors and alarms, refer to the CPU 31xC and
CPU 31x operating instructions, Setup.

Manuals containing further information


For more in-depth Getting Started information, we recommend Getting Started and
Exercises with STEP 7.

Service & Support on the Internet


In addition to our documentation, we offer a comprehensive online knowledge base on the
Internet at:
http://www.siemens.com/automation/service&support
There you can find:
● A newsletter containing the latest information on your Siemens products.
● The documents you need using our search engine in Service & Support.
● the bulletin board, a worldwide knowledge exchange for users and experts.
● your local contact for Automation & Drives in our contact database.
● Information about on-site services, repairs, spare parts. You will find much more under
"Services".

S7-300 Automation System: Getting Started CPU 31x: Commissioning


Getting Started, 06/2008, A5E00164278-04 19
Further Information

S7-300 Automation System: Getting Started CPU 31x: Commissioning


20 Getting Started, 06/2008, A5E00164278-04
1
SIMATIC S7-300 SIMATIC S7-300 Automation System S7-300: Getting Started CPU 31xC: Commissioning
______________
Introduction

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
______________
Further Information

Automation System S7-300: Getting


Started CPU 31xC: Commissioning

Getting Started

12/2006
A5E00105538-03
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00105538-03 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 12/2006 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
2 Preparation ............................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Installing the mounting rail and modules ...................................................................... 3-1
3.2 2. Step: Wiring modules............................................................................................................. 3-3
3.3 3. Step: Commissioning hardware ............................................................................................. 3-4
3.4 4. Step: Programming the circuit................................................................................................ 3-5
3.5 5. Step: Configuring hardware ................................................................................................... 3-7
3.6 6. Step: Trial run ........................................................................................................................ 3-8
4 Further Information ................................................................................................................................. 4-1
4.1 Further Information .................................................................................................................... 4-1

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 iii
Table of contents

Automation System S7-300: Getting Started CPU 31xC: Commissioning


iv Getting Started, 12/2006, A5E00105538-03
Introduction 1
Contents of this Getting Started Manual
On the basis of a practical example, this manual guides you through six commissioning
steps so that you can create a functioning application. While working through the example,
you will learn the basic hardware and software functions associated with your CPU 31xC.
This process will take 1.5 to 2 hours, depending on your experience.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 1-1
Introduction

Automation System S7-300: Getting Started CPU 31xC: Commissioning


1-2 Getting Started, 12/2006, A5E00105538-03
Preparation 2
Scope
This guide applies to the following CPUs:

CPU Order no. SIMATIC Micro Memory As of version


Card required for operation? Firmware

312C 6ES7 312-5BE03-0AB0 Yes V2.0.12


313C 6ES7 313-5BF03-0AB0 Yes V2.0.12
313C-2 PtP 6ES7 313-6BF03-0AB0 Yes V2.0.12
313C-2 DP 6ES7 313-6CF03-0AB0 Yes V2.0.12
314C-2 PtP 6ES7 314-6BG03-0AB0 Yes V2.0.12
314C-2 DP 6ES7 314-6CG03-0AB0 Yes V2.0.12

Prerequisites
• You require a basic knowledge of electronics/electrical engineering and experience of
working with computers and Microsoft® Windows™ 95/98/NT.

Warning
Depending on its area of application as part of a plant or system, the S7-300 may be
subject to specific rules and regulations. Please make sure that you adhere to the
applicable safety and accident-prevention regulations, for example, IEC 204 (emergency
stop systems).
Non-compliance with these regulations can lead to serious injury and damage to
machinery and equipment.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 2-1
Preparation

Materials and tools required

Quantity Item Order number (Siemens)


1 Mounting rail e.g. 6ES7 390-1AE80-0AA0
1 Power supply PS 307 (PS) e.g. 6ES7 307-1EA00-0AA0
1 CPU 31xC, e.g. CPU 313C e.g. 6ES7 313-5BF03-0AB0
1 SIMATIC Micro Memory Card e.g. 6ES7 953-8LL00-0AA0
Note:
The SIMATIC Micro Memory Card is essential for the operation of certain
CPUs (see Applicability).
2 40-pin front connector with screw contacts 6ES7 392-1AM00-0AA0
1 • Programming device (PG) with MPI interface and STEP 7 software as of Depending on configuration
V5.2 + SP2 installed and PG cable or
• PC with suitable interface card
Xm PROFIBUS DP cable with bus connectors Depending on implementation
Various M6 nuts and bolts (length depending on specific installation) with suitable commonly available
screwdriver/wrench
1 Screwdriver with 3.5 mm wide blade commonly available
1 Screwdriver with 4.5 mm wide blade commonly available
1 Side cutter and cable stripper commonly available
1 Crimp tool commonly available
Xm Cable with 10 mm2 cross section for grounding the rail with cable lug commonly available
suitable for M6, length depending on local situation
Approx. Flexible wire with 1 mm2 cross section with suitable ferrules with insulation commonly available
2m collar, length 6 mm
Xm 3-core power supply cable (230/120 V AC) with a "Schuko" plug with side commonly available
grounding contacts, length to suit the local situation and suitable ferrules
2 Single-pole ON switch (24 V) commonly available

Automation System S7-300: Getting Started CPU 31xC: Commissioning


2-2 Getting Started, 12/2006, A5E00105538-03
Preparation

Setup of the example

1 2 3 4

E124.1
SF 0 0 0
BF 1 1 1
2 2 2
DC5V 3 3 3
FRCE 4 4 4 A124.0
RUN E124.2 5
6
5
6
5
6
STOP
7 7 7
RUN
STOP
MRES
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7

+
24 Volt

9 8 7 6 5
Figure 2-1 Overview of the sample configuration

(1) Setting the supply voltage


(2) Mode selector
(3) Mounting rail
(4) Programming device with STEP 7 software
(5) PG cable
(6) Button
(7) Connecting cable
(8) Clamp for strain relief
(9) Power supply ON/OFF

Functionality of the example


Output Q124.0 must only switch (i.e. diode Q124.0 lights up) when button I124.1 and button
I124.2 are pressed.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 2-3
Preparation

Automation System S7-300: Getting Started CPU 31xC: Commissioning


2-4 Getting Started, 12/2006, A5E00105538-03
Learning units 3
3.1 1. Step: Installing the mounting rail and modules

Rail installation sequence


From left to right: Power supply PS 307 - CPU 313C.
The synopsis will provide you with an overview of the overall configuration.

Install and ground the mounting rail


1. Screw on the mounting rail (screw size: M6) so that at least 40 mm space remains above
and below the rail.
When mounting it on a grounded metallic panel or on a grounded device mounting panel
made of steel sheet, make sure you have a low impedance connection between the
mounting rail and the mounting surface.
2. Connect the rail to the protective conductor. An M6 screw is provided on the rail for this
purpose.
Minimum cross-section from the cable to the protective conductor: at least 10 mm2.

1.

2.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 3-1
Learning units
3.1 1. Step: Installing the mounting rail and modules

Installing modules on the mounting rail


1. Hook the power supply module onto the rail, slide it until it reaches the grounding screw
of the rail and then screw it tight.
2. Hook the CPU onto the rail (1),slide it along as far as the module on the left (2), and
swing it down into place (3).

2 1

3. Bolt the CPU tight, applying a torque of between 0.8 and 1.1 Nm.
4. Insert the micro memory card into the CPU (4); this is essential for operation.
If you do not know the content of the micro memory card, erase it first on the
programming device.

0,8 bis 1,1 Nm

Automation System S7-300: Getting Started CPU 31xC: Commissioning


3-2 Getting Started, 12/2006, A5E00105538-03
Learning units
3.2 2 . Step: Wiring modules

3.2 2. Step: Wiring modules

Warning
You could touch live wires if the power supply module PS 307 is switched on or the supply
cable of the power supply is connected to the mains supply.
Perform any wiring work on the S7-300 only when the power is off!

Wiring the power supply and the CPU


1. Open the front panel covers of the power supply module and CPU.
2. Unscrew the strain relief clamp on the power supply module.
3. Remove the insulation from the power cord, attach the cable end sleeves (for stranded
conductors), and connect them to the power supply.
4. Screw the strain-relief assembly tight.
5. Insert two short connecting cables between the power supply and the CPU and screw
them tight.
6. Check that the line voltage selector switch is set to the correct line voltage.
The default line voltage setting for the power supply module is 230 VAC. To label a front
connector, follow the steps outlined below: To change the voltage, remove the protective
cap with a screwdriver, set the switch to the required line voltage and replace the
protective cap.

Wiring the front connectors of the DI and DO


1. Open the right front panel of the CPU 313C.
2. Place the front connector into wiring position.
You do this by pushing a front connector into the CPU until it latches. In this position, the
front connector still protrudes from the CPU. In the wiring position a wired front connector
has no contact with the module.
3. Remove 6 mm of the insulation from the ends of the wires that go into the front
connector. Attach cable end sleeves to these ends.
4. Wire the front connector (DI side) as follows:
– Terminal 1: L+ of the power supply
– Terminal 3: Button 1
– Terminal 4: Button 2
– Terminal 20: M of the power supply
5. Wire the front connector (DO side) as follows:
– Terminals 21 and 31: L+ of the power supply
– Terminal 30: M of the power supply

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 3-3
Learning units
3.3 3. Step: Commissioning hardware

6. Wire the free cable ends of the button with L+ of the power supply.
7. Lead the wires downwards out of the front connector.
8. Secure the front connector with the screws (this establishes contact with the module).
9. Close the front panel covers of the power supply module and the front panel of the CPU.

3.3 3. Step: Commissioning hardware

Procedure
1. Use the PG cable to connect the programming device to the CPU. When using a cable
with PROFIBUS connectors, remember to switch on the integrated terminating resistors.
Close the front panel cover of the CPU, then set the mode selector switch on the CPU to
STOP.
2. Connect the mains cable, then switch on the power supply module PS 307.
The DC24V LED on the power supply is lit.
All the LEDs on the CPU light up briefly; the SF LED and the DC5V LED stay lit. The
STOP LED then flashes slowly to indicate a CPU memory reset.
3. Perform a CPU memory reset:
– Turn the mode switch to MRES. Hold the mode selector at this position until the STOP
LED lights up for the second time and then remains lit (approx. 3 seconds). Then
release it.
– You must press the mode switch back to MRES within 3 s. The STOP LED begins to
flash rapidly and the CPU performs a reset. You can now release the mode switch.
The CPU has completed the memory reset when the STOP LED remains permanently
lit again.
4. Start your programming device, then run SIMATIC Manager from your Windows Desktop.
A window opens with SIMATIC Manager.
5. Select button 1.
The LED of I124.1 lights up. No DO LED lights up.
6. Select button 2.
The LED of I124.2 lights up. No DO LED lights up.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


3-4 Getting Started, 12/2006, A5E00105538-03
Learning units
3.4 4 . Step: Programming the circuit

3.4 4. Step: Programming the circuit

Procedure
1. Follow the instructions of the STEP 7 "New Project" wizard on the programming device
and set up a new project with the following data:
– CPU type: CPU 313C
– Block to be created: OB 1
– Project name: S7_Pro1
A window, divided into two parts, opens with the title S7_Pro1 -- ....
2. Double-click the OB1 icon in the right-hand part of the window.
The editor for editing the OB 1 block opens.
3. In the "View" menu, select "LAD" to change to the ladder logic programming language.
At the bottom of the left-hand window, a current path is displayed in network 1.
4. Carefully click on the horizontal line representing the current path.
The line is highlighted.
5. On the toolbar, click twice on the --||-- icon (normally-open contact) and then once on the
–( ) icon (coil).
The icons are inserted into the current path.
6. Click on the red question mark for the left-hand normally- open contact in the current
path.
The normally-open contact is highlighted and the question mark is replaced with a text
input box containing the cursor.
7. Enter I124.1 and press Return.
The left-hand normally-open contact is now called I124.1.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 3-5
Learning units
3.4 4 . Step: Programming the circuit

8. Label the right button in the same way with I124.2 and the coil with Q124.0.

9. Close the editor and click Yes when you are prompted to save.
The editor is closed and OB 1 is saved.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


3-6 Getting Started, 12/2006, A5E00105538-03
Learning units
3.5 5 . Step: Configuring hardware

3.5 5. Step: Configuring hardware

Procedure
1. In SIMATIC Manager, click on SIMATIC 300 Station in the left-hand part of the window.
The Hardware and CPU 313C icons appear in the right-hand part of the window.
2. Double-click the Hardware icon in the right-hand part of the window.
The editor for editing the hardware opens.
3. If the catalog is not shown in the right section of the window, you can activate it by
selecting Catalog in the View menu.
4. Expand SIMATIC 300 and CPU-300 until you see CPU 313C.
5. Insert the CPU 313C by dragging it to slot 2 (top or bottom left-hand window).

Note
You can see the order number in the catalog if you click on a CPU. The order number of
this CPU then appears in the box beneath the catalog.

6. Check that the order number displayed for slot 2 in the lower left-hand part of the window
matches the order number of your CPU. You may need to expand the width of the order
number column to see the entire number.
If it does: Skip to the next step.
If it does not: Expand CPU-300 in the catalog until you see CPU 313C and replace the
CPU in slot 2 by dragging the CPU with the correct order number from the catalog.
7. Perform steps 3 and 4 for the power supply module PS 307 too. You insert the PS 307 in
slot 1.
8. Go to the Station menu and select Save and compile.
The hardware configuration is compiled and saved.
9. Close the editor.
The editor is closed.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 3-7
Learning units
3.6 6. Step: Trial run

3.6 6. Step: Trial run

Procedure
1. Use the SIMATIC 300 station and CPU 313C to browse to the S7 program. In SIMATIC
Manager click on Blocks in the right-hand part of the window.
Blocks will now be highlighted.
2. Select Download from the PLC menu to transfer the program and hardware configuration
to the CPU. Confirm all windows with Yes.
The program and configuration are downloaded from the programming device to the
CPU. The program is now stored on the Micro Memory Card (in the load memory), where
it is unaffected by power failures and resets.
3. Set the CPU's mode switch to RUN.
The STOP LED is switched off. The RUN LED starts to flash and then assumes a
continuous signal.
4. Press each of the buttons alternately.
The LEDs of inputs I124.1 and I124.2 light up alternately.
The LED of output Q124.0 is not lit.
5. Press both buttons simultaneously.
The LEDs of inputs I124.1 and I124.2 light up simultaneously.
The LED of output Q124.0 is lit. This would switch on a connected final controlling
element or indicator.

Automation System S7-300: Getting Started CPU 31xC: Commissioning


3-8 Getting Started, 12/2006, A5E00105538-03
Further Information 4
4.1 Further Information

Diagnostics/Correction of Errors
Wrong operation, faulty wiring or a faulty hardware configuration may cause errors which the
CPU, CP or IE/PB-Link indicate with the SF group error LED after CPU memory reset.
How to analyze such errors and alarms is described in the CPU31xC and CPU 31x operating
instructions, Setup and Programming with STEP 7 manuals.

Manuals containing further information


For more in-depth Getting Started information, we recommend Getting Started and
Exercises with STEP 7

Service & Support on the Internet


In addition to our documentation, we offer a comprehensive online knowledge base on the
Internet at:
http://www.siemens.com/automation/service&support
There you can find:
• A newsletter containing the latest information on your Siemens products.
• The documents you need using our search engine in Service & Support.
• the bulletin board, a worldwide knowledge exchange for users and experts.
• your local contact for Automation & Drives in our contact database.
• Information about on-site services, repairs, spare parts. You will find much more under
"Services".

Automation System S7-300: Getting Started CPU 31xC: Commissioning


Getting Started, 12/2006, A5E00105538-03 4-1
Further Information
4.1 Further Information

Automation System S7-300: Getting Started CPU 31xC: Commissioning


4-2 Getting Started, 12/2006, A5E00105538-03
1
SIMATIC S7-300 First Steps in Commissioning CPU 31xC: Positioning with analog output
______________
Introduction

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
S7-300 ______________
Further Information

First Steps in Commissioning


CPU 31xC: Positioning with analog
output
Getting Started

12/2006
A5E00105537-02
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00105537-02 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 01/2007 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
2 Preparation ............................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Wiring the power supply and CPU ............................................................................... 3-1
3.2 2. Step: Installing the sample project......................................................................................... 3-4
3.3 3. Step: Assigning parameters to the CPU 31xC....................................................................... 3-5
3.4 4. Step: Linking blocks to the user program .............................................................................. 3-6
3.5 5. Step: Trial run ........................................................................................................................ 3-7
4 Further Information ................................................................................................................................. 4-1
4.1 Further Information .................................................................................................................... 4-1

Tables
Table 3-1 CONNECTOR X1 ...................................................................................................................... 3-3
Table 3-2 CONNECTOR X2 ...................................................................................................................... 3-3

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 iii
Table of contents

First Steps in Commissioning CPU 31xC: Positioning with analog output


iv Getting Started, 12/2006, A5E00105537-02
Introduction 1
Contents of this Getting Started Manual
Based on a concrete example, this Getting Started manual takes you through five
commissioning steps to the point where you have a functioning traversing movement. You
will get to know certain basic hardware and software functions and will calculate and check
the application-dependent parameters in this sample. The references to the manual will also
help you to get a general overview of the information it contains.
This process will take 1 to 2 hours, depending on your experience.

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 1-1
Introduction

First Steps in Commissioning CPU 31xC: Positioning with analog output


1-2 Getting Started, 12/2006, A5E00105537-02
Preparation 2
Scope
This guide applies to the following CPUs:

CPU Order number SIMATIC Micro Memory As of version


Card required for operation? Firmware

314C-2 DP 6ES7 314-6CG03-0AB0 Yes V2.0.12


314C-2 PtP 6ES7 314-6BG03-0AB0 Yes V2.0.12

Requirements
The following requirements must be met:
• You have an S7-300 station comprising a power supply module and a CPU 314C-2
DP/PtP.
• STEP 7 as of V5.2 + SP 2 is correctly installed on your PG.
• You have the CD with the sample projects or you have downloaded the sample projects
from the Internet.
• You have set up a project for the S7-300 station.
• The PG is connected to the CPU.
• You have an external 24 V DC power supply, an encoder, a drive, and the necessary
accessories, such as a front connector and wiring material.
• You provided hardware limit switches and EMERGENCY-OFF switches for safe and
reliable operation of the system.
• The CPU is correctly connected to a power supply.

Warning
Operation of an S7-300 in plants or systems is defined by special set of rules and
regulations, based on the relevant field of application. Please observe the current safety
regulations for the prevention of accidents, for example IEC 204 (EMERGENCY-OFF
equipment).
Non-compliance with these regulations can result in serious injury and damage to both
machinery and equipment.

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 2-1
Preparation

Layout of the example

1 2 3 4

6)   
%)   
  
'&9   
)5&(   
581   
6723   
  
581
6723
05(6
 
 
 
 
 
 
 
 


9ROW

8 7 6 5

(1) For setting the line voltage


(2) Mode selector
(3) Mounting rail
(4) Programming device with STEP 7 software
(5) PG cable
(6) Connecting cable
(7) Clamp for strain relief
(8) Power supply ON/OFF

First Steps in Commissioning CPU 31xC: Positioning with analog output


2-2 Getting Started, 12/2006, A5E00105537-02
Learning units 3
3.1 1. Step: Wiring the power supply and CPU

Warning
You can come into contact with live wires if the PS 307 power supply module is turned on or
the power supply cable to the PS is connected to the main power supply. Perform any wiring
work on the S7-300 only when the power is off!

Procedure
1. Fit the wired front connectors to the CPU and tighten the securing screws.
2. Connect the power supply of the inputs and outputs:
– 24 V to X2, pins 1 and 21
– Ground to X2, pins 20 and 30
3. Connect the incremental position encoder to the 24 V power supply.
4. Connect the encoder signals (X2, pins 2 to 4).

; ;

,QFUHPHQWDOHQFRGHUV
   
6LJQDO$    
6LJQDO%    
6LJQDO1    
   
   
   
   
   
   

  


  
  
  
  
  
  
9   
0 
 
/ 
 
0

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 3-1
Learning units
3.1 1. Step: Wiring the power supply and CPU

5. Connect the power unit to the power supply.


6. Connect the signal lines of the power unit over shielded cables (X1, pin 16 or 17 and
pin 20 and X2, pins 28 and 30).

X1 X2

1 21 1 21
2 22 2 22
3 23 3 23
Power section 4 24 4 24
5 25 5 25
6 26 6 26
7 27 7 27
CONV_EN 8 28 8 28
9 29 9 29
F2 Ground 10 30 10 30
M
Current signal
F1 11 11 31
GND analog 12 12 32
13 13 33
14 14 34
15 15 35
16 16 36
17 17 37
18 18 38
L1 19 19 39
L2 20 20 40
L3

7. Strip the insulation from the shielded cables and clamp the cable shield into the shield
connection element. using the shield terminal elements.

First Steps in Commissioning CPU 31xC: Positioning with analog output


3-2 Getting Started, 12/2006, A5E00105537-02
Learning units
3.1 1. Step: Wiring the power supply and CPU

Connector pin assignment


The pin assignments described below relate only to the connectors relevant for the
positioning type.

Table 3-1 CONNECTOR X1

Pin Name/address Function


16 AO 0 (V) Voltage output, power unit
17 AO 0 (A) Current output, power unit
20 Mana Analog ground

Table 3-2 CONNECTOR X2

Pin Name/address Function


1 1 L+ 24 V power supply of the inputs
2 DI+0.0 Encoder signal A
3 DI+0.1 Encoder signal B
4 DI+0.2 Encoder signal N
5 DI+0.3 Length measurement
6 DI+0.4 Reference point switch
20 1M Ground
21 2 L+ 24 V power supply of the outputs
28 DO+0.6 CONV_EN: Power unit enable
30 2M Ground

Reference
You will find information on the remaining connectors in the documentation of the S7-300.

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 3-3
Learning units
3.2 2 . Step: Installing the sample project

3.2 2. Step: Installing the sample project

Introduction
When installing the sample project, you have the following options:

Installing from CD
1. Start the installation program on the CD by double-clicking on the SETUP.EXE file in the
SETUP folder.
The installation program is started.
2. Now follow the instructions in the installation program.

Installing from the Internet


1. Open the directory with the sample projects and start the installation program by double-
clicking on the SETUP.EXE file.
The installation program is started.
2. Now follow the instructions in the installation program.

First Steps in Commissioning CPU 31xC: Positioning with analog output


3-4 Getting Started, 12/2006, A5E00105537-02
Learning units
3.3 3 . Step: Assigning parameters to the CPU 31xC

3.3 3. Step: Assigning parameters to the CPU 31xC

Procedure
1. Open your project in SIMATIC Manager.
A window, divided into two parts, opens with the title of your project.
2. In your project, call the configuration table HW Config.

3. Double-click on the submodule "AI5/AO".


The "Properties AI5/AO2" dialog opens.
4. Disable analog output 0 by left-clicking the "Output mode" field of the "Output " tab and
select "Disabled". Close the dialog with OK.
Analog output 0 is enabled for controlling the motor power unit.
5. Double-click on the submodule "Positioning".
The "Positioning properties" dialog opens.
6. Select "Positioning with analog output". On the drive, axis and encoder tabs, customize
the properties according to your system.
7. Confirm your settings with OK.
The "Positioning properties" dialog closes.
8. Save your configuration to your project with "Station > Save and compile".
Your changes are now stored in your project.
9. When the CPU is in STOP, select "PLC > Load to module..." to download the
configuration.
The data are now downloaded from the PG to the CPU.
10.Close HW Config with "Station > Close".
You are returned to SIMATIC Manager.

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 3-5
Learning units
3.4 4. Step: Linking blocks to the user program

3.4 4. Step: Linking blocks to the user program

Procedure
1. Open the project "ZEn26_03_TF_____31xC_Pos" in the catalog
\Siemens\STEP7\Examples using the SIMATIC Manager.
A two-part window opens showing the title of the project.
2. Double-click on the S7 program "Analog 1 First Steps".
In the right-hand window, you can see the "Sources", "Blocks" and "Symbols" folders.
3. Double-click on the "Blocks" container.
This displays all the blocks of the S7 program.
4. Copy all the blocks from this folder to your project in "SIMATIC 300 Station > CPU3xx >
S7 Program > Blocks".

Chip Name (in the toolbar) Description


OB1 CYCLE_EXC Cyclic program
OB100 * COMPLETE RESTART Complete restart: Reset the
control signals
FC1 GETST_A Example 1: ANALOG, first steps
SFB44 ANALOG SFB ANALOG
DB6 DI_ANALOG Instance DB for ANALOG
VAT_GETST_A VAT_GETST_A Variable table
* Note: Adjust the values for the speed, acceleration, deceleration, and switchover and shutdown
difference in the block COMPLETE RESTART (OB 100).
1. Select it in the SIMATIC Manager under "SIMATIC 300 Station > CPU3xx > S7 Program
> Blocks".
This displays all the blocks of the S7 program.
2. Download all of the S7 blocks it contains via "PLC > Download to your CPU" (CPU in
STOP mode).
The program and configuration are downloaded from the PG to the CPU.

First Steps in Commissioning CPU 31xC: Positioning with analog output


3-6 Getting Started, 12/2006, A5E00105537-02
Learning units
3.5 5 . Step: Trial run

3.5 5. Step: Trial run

Procedure
1. In the "Function blocks" directory, double-click on the variable table "VAT_GETST_A" in
your project.
The variable table for monitoring and modifying is displayed.
2. Go online with "PLC > Connect to > Configured CPU".
At the bottom right, you will see that the CPU is set to "Stop" mode.
3. Activate monitoring with "Variable > Monitor".
The current values of the addresses are displayed in the "Status Value" column.

Caution
The next two test steps start the drive.
You can stop the drive again in one of the following ways:
• Set the control value for the direction to 0 again and activate it
• Set the control value for the drive enable to 0 again and activate it
• Change the CPU to STOP

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 3-7
Learning units
3.5 5 . Step: Trial run

4. Switch the CPU to RUN.


At the bottom right, you will see that the CPU is set to "RUN" mode.
5. Try out the two following experiments. With "Variable > Activate Modify Values", you can
make the control values valid.

"Jogging" mode
Make the following settings: You can monitor the following signal statuses in
the column "Status Value":
MODE_IN = 1: ST_ENBL = 1:
Select "Jogging" mode Start enable
DRV_EN = 1: MOD_OUT = 1:
drive enable Current mode "Jogging"
SPEED: WORKING = 1:
Speed in pulses/s Travel active
Starting the drive: ACT_POS:
DIR_P = 1: Jogging in plus direction Current actual position
DIR_M = 1: Jogging in minus direction
Remark: If both variables DIR_P and DIR_M are
activated, no positioning is possible.
"Incremental approach, relative" mode
Make the following settings: You can monitor the following signal statuses in
the column "Status Value":
MODE_IN = 4: ST_ENBL = 1:
Select "Incremental approach, relative" mode Start enable
DRV_EN = 1: MOD_OUT = 4:
drive enable Current mode "Incremental approach, relative"
TARGET: WORKING = 1:
Distance in pulses Travel active
SPEED: ACT_POS:
Speed in pulses/s Current actual position
Start drive: POS_RCD = 1:
DIR_P = 1: Incremental approach, relative in plus Position reached
direction
DIR_M = 1: Incremental approach, relative in
minus direction

First Steps in Commissioning CPU 31xC: Positioning with analog output


3-8 Getting Started, 12/2006, A5E00105537-02
Further Information 4
4.1 Further Information

Diagnostics/Correction of Errors
Incorrect operator input, faulty wiring or inconsistent configuration data may lead to errors.
For information on how to analyze such errors and messages, refer to the S7-300
documentation.

Example:
The "ZEn26_03_TF_____31xC_Pos" project contains further samples you can use for
orientation. You can customize all samples according to your personal applications.

First Steps in Commissioning CPU 31xC: Positioning with analog output


Getting Started, 12/2006, A5E00105537-02 4-1
Further Information
4.1 Further Information

First Steps in Commissioning CPU 31xC: Positioning with analog output


4-2 Getting Started, 12/2006, A5E00105537-02
1
SIMATIC S7-300 First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs
______________
Introduction

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
S7-300 ______________
Further Information

First Steps in Commissioning


CPU 31xC: Positioning with Digital
Outputs
Getting Started

12/2006
A5E00105533-02
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00105533-02 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 01/2007 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
2 Preparation ............................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Wiring the power supply and the CPU ......................................................................... 3-1
3.2 2. Step: Installing the sample project......................................................................................... 3-4
3.3 3. Step: Setting parameters ....................................................................................................... 3-5
3.4 4. Step: Linking blocks to the user program .............................................................................. 3-6
3.5 5. Step: Carrying out a dry run................................................................................................... 3-7
4 Further Information ................................................................................................................................. 4-1
4.1 Further Information .................................................................................................................... 4-1

Tables
Table 3-1 CONNECTOR X2 ...................................................................................................................... 3-4

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 iii
Table of contents

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


iv Getting Started, 12/2006, A5E00105533-02
Introduction 1
Contents of this Getting Started Manual
Based on a concrete example, this Getting Started manual takes you through five
commissioning steps to the point where you have a functioning traversing movement. You
will get to know certain basic hardware and software functions and will calculate and check
the application-dependent parameters in this sample. The references to the manual will also
help you to get a general overview of the information it contains.
This process will take 1 to 2 hours, depending on your experience.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 1-1
Introduction

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


1-2 Getting Started, 12/2006, A5E00105533-02
Preparation 2
Scope
This guide applies to the following CPUs:

CPU Order number SIMATIC Micro Memory As of version


Card required for operation? Firmware

314C-2 DP 6ES7 314-6CG03-0AB0 Yes V2.0.12


314C-2 PtP 6ES7 314-6BG03-0AB0 Yes V2.0.12

Prerequisites
• You have an S7-300 station comprising a power supply module and a CPU 314C-2
DP/PtP.
• STEP 7 as of V5.2 + SP 2 is correctly installed on your PG.
• You have the CD with the sample projects or you have downloaded the sample projects
from the Internet.
• You have set up a project for the S7-300 station.
• The PG is connected to the CPU.
• You have an external 24 V DC power supply, an encoder, a drive, and the necessary
accessories, such as a front connector and wiring material.
• You provided hardware limit switches and EMERGENCY-OFF switches for safe and
reliable operation of the system.
• The CPU is correctly connected to a power supply.

Warning
Operation of an S7-300 in plants or systems is defined by special set of rules and
regulations, based on the relevant field of application.
Please observe the current safety regulations for the prevention of accidents, for example
IEC 204 (EMERGENCY-OFF equipment).
Non-compliance with these regulations can result in serious injury and damage to both
machinery and equipment.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 2-1
Preparation

Layout of the example

1 2 3 4

6)   
%)   
  
'&9   
)5&(   
581   
6723   
  
581
6723
05(6
 
 
 
 
 
 
 
 


9ROW

8 7 6 5

(1) For setting the line voltage


(2) Mode selector
(3) Mounting rail
(4) Programming device with STEP 7 software
(5) PG cable
(6) Connecting cable
(7) Clamp for strain relief
(8) Power supply ON/OFF

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


2-2 Getting Started, 12/2006, A5E00105533-02
Learning units 3
3.1 1. Step: Wiring the power supply and the CPU

Warning
You can come into contact with live wires if the PS 307 power supply module is turned on or
the power supply cable to the PS is connected to the main power supply. Perform any wiring
work on the S7-300 only when the power is off!

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 3-1
Learning units
3.1 1. Step: Wiring the power supply and the CPU

Procedure
1. Fit the wired front connector to the CPU and tighten the securing screws.
2. Connect the power supply of the digital inputs and outputs:
– 24 V to X2, pins 1 and 31
– Ground to X2, pins 20 and 40
3. Connect the incremental position encoder to the 24 V power supply.
4. Connect the encoder signals (X2, pins 2 to 4).

; ;

,QFUHPHQWDOHQFRGHUV
   
6LJQDO$    
6LJQDO%    
6LJQDO1    
   
   
   
   
   
   

  


  
  
  
  
  
  
9   
0 
 
/ 
 
0

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


3-2 Getting Started, 12/2006, A5E00105533-02
Learning units
3.1 1. Step: Wiring the power supply and the CPU

5. Connect the relay circuit to the power supply.


6. Connect the wires of the relay circuit (X2, pin 32 to 35 and pin 40).

/RDGFXUUHQWFLUFXLW / / /


  

. .
; ;
 
 

   


   
   
. .    
 
     
   
   
0  
   
 
    
   
3ROHFKDQJLQJ
   
PRWRU
&RQWUROFLUFXLW   
  
  
  
  
  
 
  
  
  

  
  
 
( (
1&   
 
IURP
. . . .
   

.  3OXVGLUHFWLRQ ( +DUGZDUHOLPLWVZLWFKPLQXV


. . . . .  0LQXVGLUHFWLRQ ( +DUGZDUHOLPLWVZLWFKSOXV
    .
   5DSLGWUDYHUVH 
0 .  &UHHSVSHHG



7. Strip the insulation from the shielded cables and clamp the cable shield into the shield
connection element. using the shield terminal elements.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 3-3
Learning units
3.2 2. Step: Installing the sample project

Connector pin assignment


The pin assignments described below relate only to the connectors relevant for the
positioning type.

Table 3-1 CONNECTOR X2

Pin Name/address Function


1 1 L+ 24 V power supply of the inputs
2 DI+0.0 Encoder signal A
3 DI+0.1 Encoder signal B
4 DI+0.2 Encoder signal N
5 DI+0.3 Length measurement
6 DI+0.4 Reference point switch
20 1M Ground
31 3 L+ 24 V power supply of the outputs
32 DO+1.0 Digital output Q0
33 DO+1.1 Digital output Q1
34 DO+1.2 Digital output Q2
35 DO+1.3 Digital output Q3
40 3M Ground

Reference
You will find information on the remaining connectors in the documentation of the S7-300.

3.2 2. Step: Installing the sample project

Introduction
When installing the sample project, you have the following options:

Installing from CD
1. Start the installation program on the CD by double-clicking on the SETUP.EXE file in the
SETUP folder.
The installation program is started.
2. Now follow the instructions in the installation program.

Installing from the Internet


1. Open the directory with the sample projects and start the installation program by double-
clicking on the SETUP.EXE file.
The installation program is started.
2. Now follow the instructions in the installation program.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


3-4 Getting Started, 12/2006, A5E00105533-02
Learning units
3.3 3. Step: Setting parameters

3.3 3. Step: Setting parameters

Procedure
1. Open your project in SIMATIC Manager.
A window, divided into two parts, opens with the title of your project.
2. In your project, call the configuration table HW Config.

3. Double-click on the submodule "Positioning".


The "Positioning properties" dialog opens.
4. Select "Positioning with digital outputs". On the drive, axis and encoder tabs, customize
the properties according to your system.
5. Confirm your settings with "OK".
The "Positioning properties" dialog closes.
6. Save your configuration to your project with "Station > Save and compile".
Your changes are now stored in your project.
7. When the CPU is in STOP, select "PLC > Load to module..." to download the
configuration.
The data are now downloaded from the PG to the CPU.
8. Close HW Config with "Station > Close".
You are returned to SIMATIC Manager.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 3-5
Learning units
3.4 4. Step: Linking blocks to the user program

3.4 4. Step: Linking blocks to the user program

Procedure
1. Open the project "ZEn26_03_TF_____31xC_Pos" in the catalog
\Siemens\STEP7\Examples using the SIMATIC Manager.
A two-part window opens showing the title of the project.
2. Double-click on the S7 program "Digital 1 First Steps".
In the right-hand window, you can see the "Sources", "Blocks" and "Symbols" folders.
3. Double-click on the "Blocks" container.
This displays all the blocks of the S7 program.
4. Copy all the blocks from this folder to your project in "SIMATIC 300 Station > CPU3xx >
S7 Program > Blocks".

Block Name (in the toolbar) Description


OB1 CYCLE_EXC Cyclic program
OB100 * COMPLETE RESTART Complete restart: Reset the
control signals
FC1 GETST_A Getting Started DIGITAL
SFB46 DIGITAL System function block POS
DIGITAL
DB6 DI_DIGITAL Instance DB for the SFB
DIGITAL
VAT_GETST_A VAT_GETST_A Variable table
* Adjust the values for the switchover and shutdown difference in the block COMPLETE RESTART
(OB 100).
1. Select it in the SIMATIC Manager under "SIMATIC 300 Station > CPU3xx > S7 Program
> Blocks".
This displays all the blocks of the S7 program.
2. Download all of the S7 blocks it contains via "PLC > Download to your CPU" (CPU in
STOP mode).
The program and configuration are downloaded from the PG to the CPU.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


3-6 Getting Started, 12/2006, A5E00105533-02
Learning units
3.5 5 . Step: Carrying out a dry run

3.5 5. Step: Carrying out a dry run

Procedure
1. In the "Blocks" directory, double-click on the variable table "VAT_GETST_d" in your
project.
The variable table for monitoring and modifying is displayed.
2. Go online with "PLC > Connect to > Configured CPU".
At the bottom right, you will see that the CPU is set to "Stop" mode.
3. Activate monitoring with "Variable > Monitor".
The current values of the addresses are displayed in the "Status Value" column.

Caution
The next two test steps start the drive.
You can stop the drive again in one of the following ways:
• Set the control value for the direction to 0 again and activate it
• Set the control value for the drive enable to 0 again and activate it
• Change the CPU to STOP

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 3-7
Learning units
3.5 5 . Step: Carrying out a dry run

4. Switch the CPU to RUN.


At the bottom right, you will see that the CPU is set to "RUN" mode.
5. Try out the two following experiments. With "Variable > Activate Modify Values", you can
make the control values valid.

"Jogging" mode
Make the following settings: You can monitor the following signal statuses in
the column "Status Value":
MODE_IN = 1: ST_ENBL = 1:
Select "Jogging" mode Start enable
DRV_EN = 1: MOD_OUT = 1:
drive enable Current mode "Jogging"
SPEED: WORKING = 1:
Speed: 0=Creep speed, 1=Rapid traverse Travel active
Starting the drive: ACT_POS:
DIR_P = 1: Jogging in plus direction Current actual position
DIR_M = 1: Jogging in minus direction
Note: If both variables DIR_P and DIR_M are
activated, no positioning is possible.
"Incremental approach, relative" mode
Make the following settings: You can monitor the following signal statuses in
the column "Status Value":
MODE_IN = 4: ST_ENBL = 1:
Select "Incremental approach, relative" mode Start enable
DRV_EN = 1: MOD_OUT = 4:
drive enable Current mode "Incremental approach, relative"
TARGET: WORKING = 1:
Distance in pulses Travel active
SPEED: ACT_POS:
Speed: 0=Creep speed, 1=Rapid traverse Current actual position
Start drive: POS_RCD = 1:
DIR_P = 1: Incremental approach, relative in plus Position reached
direction
DIR_M = 1: Incremental approach, relative in
minus direction

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


3-8 Getting Started, 12/2006, A5E00105533-02
Further Information 4
4.1 Further Information

Diagnostics/Correction of Errors
Incorrect operator input, faulty wiring or inconsistent configuration data may lead to errors.
For information on how to analyze such errors and messages, refer to the S7-300
documentation.

Example:
The "ZEn26_03_TF_____31xC_Pos" project contains further samples you can use for
orientation. You can customize all samples according to your personal applications.

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


Getting Started, 12/2006, A5E00105533-02 4-1
Further Information
4.1 Further Information

First Steps in Commissioning CPU 31xC: Positioning with Digital Outputs


4-2 Getting Started, 12/2006, A5E00105533-02
1
SIMATIC S7-300 Getting Started - Commissioning a CPU 31xC: Counting
______________
Introduction

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
S7-300 ______________
Further Information

Getting Started - Commissioning a


CPU 31xC: Counting

Getting Started

12/2006
A5E00105536-02
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00105536-02 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 01/2007 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
2 Preparation ............................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Wiring the power supply and CPU ............................................................................... 3-1
3.2 2. Step: Installing the sample project......................................................................................... 3-3
3.3 3. Step: Setting parameters ....................................................................................................... 3-4
3.4 4. Step: Linking to the user program.......................................................................................... 3-5
3.5 5. Step: Trial run ........................................................................................................................ 3-6
4 Further Information ................................................................................................................................. 4-1
4.1 Further Information .................................................................................................................... 4-1

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 iii
Table of contents

Getting Started - Commissioning a CPU 31xC: Counting


iv Getting Started, 12/2006, A5E00105536-02
Introduction 1
Contents of this Getting Started Manual
The sample in this Getting Started manual takes you through five steps, showing you how to
commission a fully functional counter application. You are going to familiarize yourself with
the basic hardware and software functions and learn how to operate the counting function.
The references to the manual will also help you to get a general overview of the information
it contains. Additional notes relating to the frequency-measurement and pulse-width-
modulation applications are found on the sample project CD.
This process will take 1 to 2 hours, depending on your experience.

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 1-1
Introduction

Getting Started - Commissioning a CPU 31xC: Counting


1-2 Getting Started, 12/2006, A5E00105536-02
Preparation 2
Scope
This guide applies to the following CPUs:

CPU Order no. SIMATIC Micro Memory As of version


Card required for operation? Firmware

312C 6ES7 312-5BE03-0AB0 Yes V2.0.12


313C 6ES7 313-5BF03-0AB0 Yes V2.0.12
313C-2 PtP 6ES7 313-6BF03-0AB0 Yes V2.0.12
313C-2 DP 6ES7 313-6CF03-0AB0 Yes V2.0.12
314C-2 PtP 6ES7 314-6BG03-0AB0 Yes V2.0.12
314C-2 DP 6ES7 314-6CG03-0AB0 Yes V2.0.12

Prerequisites
• You have an S7-300 station comprising a power supply module and a CPU 31xC.
• STEP 7 as of V5.2 + SP 2 is correctly installed on your PG.
• You have the CD with the sample projects or you have downloaded the sample projects
from the Internet.
• You have set up a project for the S7-300 station.
• The PG is connected to the CPU.
• You are set up with all the required accessories, e.g., front connector and wiring material.
• The CPU is correctly connected to a power supply.

Warning
Operation of an S7-300 in plants or systems is defined by special set of rules and
regulations, based on the relevant field of application. Please observe the current safety
regulations for the prevention of accidents, for example IEC 204 (EMERGENCY-OFF
equipment).
Non-compliance with these regulations can result in serious injury and damage to both
machinery and equipment.

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 2-1
Preparation

Layout of the example

1 2 3 4

6)   
%)   
  
'&9   
)5&(   
581   
6723   
  
581
6723
05(6
 
 
 
 
 
 
 
 


9ROW

8 7 6 5

(1) For setting the line voltage


(2) Mode selector
(3) Mounting rail
(4) Programming device with STEP 7 software
(5) PG cable
(6) Connecting cable
(7) Clamp for strain relief
(8) Power supply ON/OFF

Getting Started - Commissioning a CPU 31xC: Counting


2-2 Getting Started, 12/2006, A5E00105536-02
Learning units 3
3.1 1. Step: Wiring the power supply and CPU

Warning
You can come into contact with live wires if the PS 307 power supply module is turned on or
the power supply cable to the PS is connected to the main power supply. Perform any wiring
work on the S7-300 only when the power is off!

Procedure
1. Fit the front connector to the CPU and tighten the securing screws.
2. Wire the connections for the "Count 1 First Steps" sample project as follows:

Connector pin assignment


The pin assignments described below relate only to the connectors relevant for the
positioning type.

CPU 312C Name/address Sample function


connection: X1
2 DI+0.0 Pulse input
3 DI+0.1 Direction bit
4 DI+0.2 Hardware gate
8 DI+0.6 Latch input
12 2M Reference potential of the supply voltage
13 1 L+ 24 V DC supply voltage
16 DO+0.2 Simulation: Pulse input -> connect to DI+0.0
17 DO+0.3 Simulation: Direction bit -> connect to DI+0.1
18 DO+0.4 Simulation: Hardware gate -> connect to DI+0.2
19 DO+0.5 Simulation: Latch input -> connect to DI+0.6
20 1M Reference potential of the supply voltage

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 3-1
Learning units
3.1 1. Step: Wiring the power supply and CPU

Pin Name/address Function


CPU 313C-2 DP/PtP: X1
CPU 313C, 314C-2
DP/PtP: X2
1 1 L+ 24 V power supply of the inputs
2 DI+0.0 Pulse input
3 DI+0.1 Direction bit
4 DI+0.2 Hardware gate
16 DI+1.4 Latch input
20 1M Reference potential of the supply voltage
21 2 L+ 24 V power supply of the outputs
24 DO+0.2 Simulation: Pulse input -> connect to DI+0.0
25 DO+0.3 Simulation: Direction bit -> connect to DI+0.1
26 DO+0.4 Simulation: Hardware gate -> connect to DI+0.2
27 DO+0.5 Simulation: Latch input -> connect to DI+1.4
30 2M Reference potential of the supply voltage
The figure shows, as an example, the CPU 314C with a standard plug arrangement for
CPUs with two connectors (X1 and X2).

RUN
STOP
MRES

L+ M

Reference
You will find information on the remaining connectors in the documentation of the S7-300.

Getting Started - Commissioning a CPU 31xC: Counting


3-2 Getting Started, 12/2006, A5E00105536-02
Learning units
3.2 2. Step: Installing the sample project

3.2 2. Step: Installing the sample project

Introduction
When installing the sample project, you have the following options:

Installing from CD
1. Start the installation program on the CD by double-clicking on the SETUP.EXE file in the
SETUP folder.
The installation program is started.
2. Now follow the instructions in the installation program.

Installing from the Internet


1. Open the directory with the sample projects and start the installation program by double-
clicking on the SETUP.EXE file.
The installation program is started.
2. Now follow the instructions in the installation program.

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 3-3
Learning units
3.3 3 . Step: Setting parameters

3.3 3. Step: Setting parameters

Procedure
1. Open your project in SIMATIC Manager.
A window, divided into two parts, opens with the title of your project.
2. In your project, call the configuration table HW Config.

3. Double-click on the submodule "Counting".


The "Counting properties" dialog opens.
4. Select channel 0 and "Infinite count" mode. Make the following settings in the parameter
assignment screen forms (do not modify any other settings, as they are not required for
commissioning):
– Input: Hardware gate
– Output reaction: Counter value ≥ Comparison value
5. Confirm your settings with "OK".
The "Counting properties" dialog closes.
6. Save your configuration to your project with "Station > Save and compile".
Your changes are now stored in your project.
7. When the CPU is in STOP, select "PLC > Load to module..." to download the
configuration.
The data are now downloaded from the PG to the CPU.
8. Close HW Config with "Station > Close".
You are returned to SIMATIC Manager.

Getting Started - Commissioning a CPU 31xC: Counting


3-4 Getting Started, 12/2006, A5E00105536-02
Learning units
3.4 4. Step: Linking to the user program

3.4 4. Step: Linking to the user program

Procedure
1. Open the project "ZEn26_02_TF_____31xC_Cnt" in the catalog
\Siemens\STEP7\Examples via "File > Open... > Sample projects" in SIMATIC Manager.
A two-part window opens showing the title of the project.
2. Double-click on the S7 program "Count 1 First Steps".
In the right-hand window, you can see the "Sources", "Blocks" and "Symbols" folders.
3. Double-click on the "Blocks" container.
This displays all the blocks of the S7 program.
4. Copy all the blocks from this folder to your project in "SIMATIC 300 Station > CPU3xx >
S7 Program > Blocks".

Chip Name (in the toolbar) Description


OB1 CYCLE_EXC Cyclic program
FB11 GETST_C Example 1: COUNT, first steps
DB11 DI_GETST_C Instance DB for GETST_C
SFB47 COUNT SFB COUNT
DB16 DI_COUNT Instance DB for SFB COUNT
VAT VAT_GETST_C Variable table
1. Copy the symbol table to your project in "SIMATIC 300 Station > CPU3xx > S7 Program".
The symbol table is stored in your project.
2. In SIMATIC Manager, select "SIMATIC 300 Station > CPU3xx > S7 Program > Function
blocks".
This displays all the blocks of the S7 program.
3. Download all of the S7 blocks it contains to your CPU via "PLC > Download" (CPU in
STOP mode).
The program and configuration are downloaded from the PG to the CPU.

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 3-5
Learning units
3.5 5 . Step: Trial run

3.5 5. Step: Trial run

Procedure
1. In the "Function blocks" directory, double-click on the variable table "VAT_GETST_C" in
your project.
The variable table for monitoring and modifying is displayed.
2. Go online with "PLC > Connect to > Configured CPU".
At the bottom right, you will see that the CPU is set to "Stop" mode.
3. Activate monitoring with "Variable > Monitor".
The current values of the addresses are displayed in the "Status Value" column.
4. Switch the CPU to RUN.
At the bottom right, you will see that the CPU is set to "RUN" mode.
5. In the variable S_IMP_H of the VAT, select the count pulse source:
– S_IMP_H = 0:
The pulse source is a programmed SW clock generator. Its frequency is adjustable via
the T_PULSE variable. The clock is connected to the pulse input via a digital output.
– S_IMP_H = 1:
Specify the count pulses by manually setting and resetting the S_IMP_T variable in the
VAT.
6. You can perform the following tests:

Starting/stopping the counter:


• Start the counter by setting the variables You can monitor the actual counter value at the
SW_GATE (SFB parameter SW gate) and SFB output parameter COUNTVAL. You can
S_HWT (simulation of HW gate) in the VAT to view the status of the SW or HW gate in the
1 (logical AND). variables STS_GATE or STS_STRT.
• Stop the counter by resetting S_HWT or
SW_GATE to zero.
Loading a count value to the counter:
• JOB_ID = 01 hex ("Write counter directly") You can view the loaded count value at the SFB
• JOB_VAL = Count value (-231 to +231-1) output parameter COUNTVAL. If no load error
• JOB_REQ = 1, has occurred, the status at the output
parameters is JOB_DONE = 1 and JOB_ERROR
Job initiates at the positive edge = 0.

Getting Started - Commissioning a CPU 31xC: Counting


3-6 Getting Started, 12/2006, A5E00105536-02
Further Information 4
4.1 Further Information

Diagnostics/Correction of Errors
Incorrect operator input, faulty wiring or inconsistent configuration data may lead to errors.
For information on how to analyze such errors and messages, refer to the S7-300
documentation.

Example:
The "ZEn26_02_TF_____31xC_Cnt" project contains further samples you can use for
orientation. You can customize all samples according to your personal applications.

Getting Started - Commissioning a CPU 31xC: Counting


Getting Started, 12/2006, A5E00105536-02 4-1
Further Information
4.1 Further Information

Getting Started - Commissioning a CPU 31xC: Counting


4-2 Getting Started, 12/2006, A5E00105536-02
1
SIMATIC S7-300 Getting Started - Commissioning a CPU 31xC: Point-to-point link
______________
Introduction

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
S7-300 ______________
Further Information

Getting Started - Commissioning a


CPU 31xC: Point-to-point link

Getting Started

12/2006
A5E00105535-02
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00105535-02 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 12/2006 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
2 Preparation ............................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Installing the sample project......................................................................................... 3-1
3.2 2. Step: Setting parameters ....................................................................................................... 3-2
3.3 3. Step: Linking to the user program.......................................................................................... 3-3
3.4 4. Step: Trial run ........................................................................................................................ 3-4
4 Further Information ................................................................................................................................. 4-1
4.1 Further Information .................................................................................................................... 4-1

Getting Started - Commissioning a CPU 31xC: Point-to-point link


Getting Started, 12/2006, A5E00105535-02 iii
Table of contents

Getting Started - Commissioning a CPU 31xC: Point-to-point link


iv Getting Started, 12/2006, A5E00105535-02
Introduction 1
Contents of this Getting Started Manual
The sample in this Getting Started manual takes you through four steps, showing you how to
commission a fully functional application. You are going to familiarize yourself with the basic
hardware and software functions and learn how to transfer data via a serial interface. The
references to the manual will also help you to get a general overview of the information it
contains.
This process will take 1 to 2 hours, depending on your experience.

Getting Started - Commissioning a CPU 31xC: Point-to-point link


Getting Started, 12/2006, A5E00105535-02 1-1
Introduction

Getting Started - Commissioning a CPU 31xC: Point-to-point link


1-2 Getting Started, 12/2006, A5E00105535-02
Preparation 2
Scope
This guide applies to the following CPUs:

CPU Order number SIMATIC Micro Memory As of version


Card required for operation? Firmware

313C-2 PtP 6ES7 313-6BF03-0AB0 Yes V2.0.12


314C-2 PtP 6ES7 314-6BG03-0AB0 Yes V2.0.12

Prerequisites
• You have an S7-300 station comprising a power supply module and a CPU 31xC-2 PtP.
The serial connection is established via the 15-pole sub-D socket at the right side.
• STEP 7 as of V5.2 + SP 2 is correctly installed on your PG.
• You have the CD with the sample projects or you have downloaded the sample projects
from the Internet.
• You have set up a project for the S7-300 station.
• The PG is connected to the CPU.
• You have prepared your connection partner for serial data transfer and connected the
required patch cord.
• The CPU is correctly connected to a power supply.

Warning
Operation of an S7-300 in plants or systems is defined by special set of rules and
regulations, based on the relevant field of application. Please observe the current safety
regulations for the prevention of accidents, for example IEC 204 (EMERGENCY-OFF
equipment).
Non-compliance with these regulations can result in serious injury and damage to both
machinery and equipment.
You can come into contact with live wires if the PS 307 power supply module is turned on
or the power supply cable to the PS is connected to the main power supply. Perform any
wiring work on the S7-300 only when the power is off!

Getting Started - Commissioning a CPU 31xC: Point-to-point link


Getting Started, 12/2006, A5E00105535-02 2-1
Preparation

Layout of the example

1 2 3 4

6)   
%)   
  
'&9   
)5&(   
581   
6723   
  
581
6723
05(6
 
 
 
 
 
 
 
 


9ROW

8 7 6 5

(1) For setting the line voltage


(2) Mode selector
(3) Mounting rail
(4) Programming device with STEP 7 software
(5) PG cable
(6) Connecting cable
(7) Clamp for strain relief
(8) Power supply ON/OFF

Getting Started - Commissioning a CPU 31xC: Point-to-point link


2-2 Getting Started, 12/2006, A5E00105535-02
Learning units 3
3.1 1. Step: Installing the sample project

Introduction
When installing the sample project, you have the following options:

Installing from CD
1. Start the installation program on the CD by double-clicking on the SETUP.EXE file in the
SETUP folder.
The installation program is started.
2. Now follow the instructions in the installation program.

Installing from the Internet


1. Open the directory with the sample projects and start the installation program by double-
clicking on the SETUP.EXE file.
The installation program is started.
2. Now follow the instructions in the installation program.

Getting Started - Commissioning a CPU 31xC: Point-to-point link


Getting Started, 12/2006, A5E00105535-02 3-1
Learning units
3.2 2 . Step: Setting parameters

3.2 2. Step: Setting parameters

Procedure
1. Open your project in SIMATIC Manager.
A window, divided into two parts, opens with the title of your project.
2. In your project, call the configuration table HW Config.

3. Double-click on the submodule "PtP".


The "PtP properties" dialog opens.
4. Select the "ASCII" protocol and enter the default settings in the parameter masks with a
click on "OK":
– 9600 bits/s, 8 data bits, 1 stop bit, even parity
5. Confirm your settings with "OK".
The "PtP properties" dialog closes.
6. Save your configuration to your project with "Station > Save and compile".
Your changes are now stored in your project.
7. When the CPU is in STOP, select "PLC > Load to module..." to download the
configuration.
The data are now downloaded from the PG to the CPU.
8. Close HW Config with "Station > Close".
You are returned to SIMATIC Manager.

Getting Started - Commissioning a CPU 31xC: Point-to-point link


3-2 Getting Started, 12/2006, A5E00105535-02
Learning units
3.3 3. Step: Linking to the user program

3.3 3. Step: Linking to the user program

Procedure
1. Open the project "ZEn26_01_TF_____31xC_PtP" in the catalog
\Siemens\STEP7\Examples via "File > Open... > Sample projects" in the SIMATIC
Manager.
A two-part window opens showing the title of the project.
2. Double-click on the station "CPU 31xC ASCII".
Your station is opened.
3. Open the S7 program for the station CPU and double-click on the "Function blocks"
container.
This displays all the blocks of the S7 program.
4. With the exception of system data, copy all the function blocks from this folder to your
project in "SIMATIC 300 Station > CPU3xx > S7 Program > Function blocks".

Chip Name (in the toolbar) Description


OB1 CYCLE Cyclic program processing
OB100 RESTART Startup processing restart
DB21 SEND IDB Instance DB for SEND_PTP SFB
DB22 RCV IDB Instance DB for RCV_PTP SFB
DB40 SEND WORK DB Work DB for SEND_PTP SFB
DB41 RCV WORK DB Work DB for RCV_PTP SFB
DB42 SEND SRC DB Send DB
DB43 RCV DST DB Receive DB
SFB60 SEND_PTP Send SFB for data
SFB61 RCV_PTP Receive SFB for data
FB21 SEND Sending Data
FB22 RECEIVE Receiving Data
VAT1 - VAT1
1. In SIMATIC Manager, select "SIMATIC 300 Station > CPU3xx > S7 Program > Function
blocks".
This displays all the blocks of the S7 program.
2. Download all of the S7 function blocks it contains to your CPU via "PLC > Download"
(CPU in STOP mode).
The program and configuration are downloaded from the PG to the CPU.

Getting Started - Commissioning a CPU 31xC: Point-to-point link


Getting Started, 12/2006, A5E00105535-02 3-3
Learning units
3.4 4. Step: Trial run

3.4 4. Step: Trial run

Procedure
1. In the "Function blocks" directory, double-click on the variable table "VAT1" in your
project.
The variable table for monitoring and modifying is displayed.
2. Go online with "PLC > Connect to > Configured CPU".
At the bottom right, you will see that the CPU is set to "Stop" mode.
3. Activate monitoring with "Variable > Monitor".
The current values of the addresses are displayed in the "Status Value" column.
4. Switch the CPU to RUN.
At the bottom right, you will see that the CPU is set to "RUN" mode. Data transfer is
started. You can view the number of transmissions at the operand "DB42.DBW0" (Send
counter). "DB41.DBW18" (Receive counter) indicates data is being received.

Getting Started - Commissioning a CPU 31xC: Point-to-point link


3-4 Getting Started, 12/2006, A5E00105535-02
Further Information 4
4.1 Further Information

Diagnostics/Correction of Errors
Incorrect operator input, faulty wiring of the serial interface or inconsistent configuration data
may lead to errors.
For information on how to analyze such errors and messages, refer to the S7-300
documentation.

Example:
The "ZEn26_01_TF_____31xC_PtP" project contains further samples you can use for
orientation. You can customize all samples according to your personal applications.

Getting Started - Commissioning a CPU 31xC: Point-to-point link


Getting Started, 12/2006, A5E00105535-02 4-1
Further Information
4.1 Further Information

Getting Started - Commissioning a CPU 31xC: Point-to-point link


4-2 Getting Started, 12/2006, A5E00105535-02
1
SIMATIC S7-300 Getting Started - Commissioning a CPU 31xC: Closed-loop control
______________
Introduction

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
S7-300 ______________
Further Information

Getting Started - Commissioning a


CPU 31xC: Closed-loop control

Getting Started

12/2006
A5E00105534-02
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00105534-02 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 01/2007 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
2 Preparation ............................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Installing the sample project......................................................................................... 3-1
3.2 2. Step: Linking to the user program.......................................................................................... 3-2
3.3 3. Step: Setting parameters ....................................................................................................... 3-2
3.4 4. Step: Trial run ........................................................................................................................ 3-3
4 Further Information ................................................................................................................................. 4-1
4.1 Further Information .................................................................................................................... 4-1

Getting Started - Commissioning a CPU 31xC: Closed-loop control


Getting Started, 12/2006, A5E00105534-02 iii
Table of contents

Getting Started - Commissioning a CPU 31xC: Closed-loop control


iv Getting Started, 12/2006, A5E00105534-02
Introduction 1
Contents of this Getting Started Manual
The practical sample in this Getting Started manual takes you through four steps, showing
you how to commission a fully functional application. You are going to learn how to
determine and configure application-dependent data and how to operate a control circuit.
The references to the manual will also help you to get a general overview of the information
it contains.
This process will take 1 to 2 hours, depending on your experience.

Getting Started - Commissioning a CPU 31xC: Closed-loop control


Getting Started, 12/2006, A5E00105534-02 1-1
Introduction

Getting Started - Commissioning a CPU 31xC: Closed-loop control


1-2 Getting Started, 12/2006, A5E00105534-02
Preparation 2
Scope
This guide applies to the following CPUs:

CPU Order no. SIMATIC Micro Memory As of version


Card required for operation? Firmware

313C 6ES7 313-5BF03-0AB0 Yes V2.0.12


313C-2 PtP 6ES7 313-6BF03-0AB0 Yes V2.0.12
313C-2 DP 6ES7 313-6CF03-0AB0 Yes V2.0.12
314C-2 PtP 6ES7 314-6BG03-0AB0 Yes V2.0.12
314C-2 DP 6ES7 314-6CG03-0AB0 Yes V2.0.12

Prerequisites
• You have an S7-300 station comprising a power supply module and a CPU 313C or
314C.
• STEP 7 as of V5.2 + SP 2 is correctly installed on your PG.
• You have the CD with the sample projects or you have downloaded the sample projects
from the Internet.
• You have set up a project for the S7-300 station.
• The PG is connected to the CPU.
• The CPU is correctly connected to a power supply.
• I/O wiring is not required for this sample.

Warning
Operation of an S7-300 in plants or systems is defined by special set of rules and
regulations, based on the relevant field of application. Please observe the current safety
regulations for the prevention of accidents, for example IEC 204 (EMERGENCY-OFF
equipment).
Non-compliance with these regulations can result in serious injury and damage to both
machinery and equipment.
You can come into contact with live wires if the PS 307 power supply module is turned on
or the power supply cable to the PS is connected to the main power supply. Perform any
wiring work on the S7-300 only when the power is off!

Getting Started - Commissioning a CPU 31xC: Closed-loop control


Getting Started, 12/2006, A5E00105534-02 2-1
Preparation

Layout of the example

1 2 3 4

6)   
%)   
  
'&9   
)5&(   
581   
6723   
  
581
6723
05(6
 
 
 
 
 
 
 
 


9ROW

8 7 6 5

(1) For setting the line voltage


(2) Mode selector
(3) Mounting rail
(4) Programming device with STEP 7 software
(5) PG cable
(6) Connecting cable
(7) Clamp for strain relief
(8) Power supply ON/OFF

Getting Started - Commissioning a CPU 31xC: Closed-loop control


2-2 Getting Started, 12/2006, A5E00105534-02
Learning units 3
3.1 1. Step: Installing the sample project

Introduction
When installing the sample project, you have the following options:

Installing from CD
1. Start the installation program on the CD by double-clicking on the SETUP.EXE file in the
SETUP folder.
The installation program is started.
2. Now follow the instructions in the installation program.

Installing from the Internet


1. Open the directory with the sample projects and start the installation program by double-
clicking on the SETUP.EXE file.
The installation program is started.
2. Now follow the instructions in the installation program.

Getting Started - Commissioning a CPU 31xC: Closed-loop control


Getting Started, 12/2006, A5E00105534-02 3-1
Learning units
3.2 2 . Step: Linking to the user program

3.2 2. Step: Linking to the user program

Procedure
1. Open the project "ZEn26_04_TF_____31xC_PID" in the catalog
\Siemens\STEP7\Examples via "File > Open... > Sample projects" in SIMATIC Manager.
A two-part window opens showing the title of the project.
2. Double-click the S7 program "Controlling 2 CONT_C".
In the right-hand window, you can see the "Sources", "Blocks" and "Symbols" folders.
3. Double-click on the "Blocks" container.
This displays all the blocks of the S7 program.
4. With the exception of system data, copy all the blocks from this folder to your project in
"SIMATIC 300 Station > CPU3xx > S7 Program > Function blocks".

Chip Name (in the toolbar) Description


OB100 RESTART Restart OB
OB35 CYC_INT5 Time-controlled OB 100 ms
SFB41 CONT_C Continuous-action PID controller
FB100 PROC_C Control circuit for the continuous controller
DB100 DI_PROC_C Instance DB for PROC_C
DB101 DI_CONT_C Instance DB for CONT_C
VAT1 VAT 1 Variable table

3.3 3. Step: Setting parameters

Procedure
1. Start the parameter assignment screen form via SIMATIC/STEP7/Configure PID Control.
The input dialog "PID Control" is displayed.
2. In PID control, open your project with "File > Open". Select instance DB101 for SFB 41
and confirm the dialog with "OK".
You are returned to the parameter assignment screen form. The configured parameters
are displayed. Changes to this sample program are not required.
3. Close the parameter assignment screen form with "File > Close".
The parameter assignment screen form is closed.
4. In SIMATIC Manager, select "SIMATIC 300 Station > CPU3xx > S7 Program > Function
blocks".
This displays all the blocks of the S7 program.
5. Download all of the S7 blocks it contains to your CPU via "PLC > Download" (CPU in
STOP mode).
The program and configuration are downloaded from the PG to the CPU.

Getting Started - Commissioning a CPU 31xC: Closed-loop control


3-2 Getting Started, 12/2006, A5E00105534-02
Learning units
3.4 4. Step: Trial run

3.4 4. Step: Trial run

Procedure
1. In the "Function blocks" directory, double-click on the variable table "VAT1" in your
project.
The variable table for monitoring and modifying is displayed.
2. Go online with "PLC > Connect to > Configured CPU".
At the bottom right, you will see that the CPU is set to "STOP" mode.
3. Activate monitoring with "Variable > Monitor".
The current values of the addresses are displayed in the "Status Value" column.
4. Switch the CPU to RUN.
At the bottom right, you will see that the CPU is set to "RUN" mode. The controller is
started.
5. Modify the setpoint "SP_INT".
You can monitor the output value "OUTV" that is proportional to the setpoint "SP_INT".
6. Call the STEP 7 tool PID Control (see step 3). Select IDB101 and click on "Online" mode.
In the "Test" menu, select and start the curve plotter function.
You can view the graphic profile of some of the control variables (actual value, setpoint,
control offset, etc.).

Getting Started - Commissioning a CPU 31xC: Closed-loop control


Getting Started, 12/2006, A5E00105534-02 3-3
Learning units
3.4 4. Step: Trial run

Getting Started - Commissioning a CPU 31xC: Closed-loop control


3-4 Getting Started, 12/2006, A5E00105534-02
Further Information 4
4.1 Further Information

Diagnostics/Correction of Errors
Incorrect operator input or inconsistent configuration data may lead to errors.
For information on how to analyze such errors and messages, refer to the S7-300
documentation.

Example:
The "ZEn26_04_TF_____31xC_PID" project contains further samples you can use for
orientation. You can customize all samples according to your personal applications.

Getting Started - Commissioning a CPU 31xC: Closed-loop control


Getting Started, 12/2006, A5E00105534-02 4-1
Further Information
4.1 Further Information

Getting Started - Commissioning a CPU 31xC: Closed-loop control


4-2 Getting Started, 12/2006, A5E00105534-02
1
SIMATIC PROFINET SIMATIC PROFINET CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET
______________
Introduction
interface

2
______________
Preparation

3
SIMATIC ______________
Learning units

4
PROFINET ______________
Further Information

CPU 315-2 PN/DP, 317-2 PN/DP,


319-3 PN/DP: Configuring the
PROFINET interface
Getting Started

12/2006
A5E00268410-03
Safety Guidelines
This manual contains notices you have to observe in order to ensure your personal safety, as well as to prevent
damage to property. The notices referring to your personal safety are highlighted in the manual by a safety alert
symbol, notices referring only to property damage have no safety alert symbol. These notices shown below are
graded according to the degree of danger.

Danger
indicates that death or severe personal injury will result if proper precautions are not taken.

Warning
indicates that death or severe personal injury may result if proper precautions are not taken.

Caution
with a safety alert symbol, indicates that minor personal injury can result if proper precautions are not taken.

Caution
without a safety alert symbol, indicates that property damage can result if proper precautions are not taken.

Notice
indicates that an unintended result or situation can occur if the corresponding information is not taken into
account.
If more than one degree of danger is present, the warning notice representing the highest degree of danger will
be used. A notice warning of injury to persons with a safety alert symbol may also include a warning relating to
property damage.

Qualified Personnel
The device/system may only be set up and used in conjunction with this documentation. Commissioning and
operation of a device/system may only be performed by qualified personnel. Within the context of the safety notes
in this documentation qualified persons are defined as persons who are authorized to commission, ground and
label devices, systems and circuits in accordance with established safety practices and standards.

Prescribed Usage
Note the following:

Warning
This device may only be used for the applications described in the catalog or the technical description and only in
connection with devices or components from other manufacturers which have been approved or recommended by
Siemens. Correct, reliable operation of the product requires proper transport, storage, positioning and assembly
as well as careful operation and maintenance.

Trademarks
All names identified by ® are registered trademarks of the Siemens AG. The remaining trademarks in this
publication may be trademarks whose use by third parties for their own purposes could violate the rights of the
owner.

Disclaimer of Liability
We have reviewed the contents of this publication to ensure consistency with the hardware and software
described. Since variance cannot be precluded entirely, we cannot guarantee full consistency. However, the
information in this publication is reviewed regularly and any necessary corrections are included in subsequent
editions.

Siemens AG Order No.: A5E00268410-03 Copyright © Siemens AG 2006.


Automation and Drives Ⓟ 12/2006 Technical data subject to change
Postfach 48 48
90437 NÜRNBERG
GERMANY
Table of contents
1 Introduction............................................................................................................................................. 1-1
1.1 Introduction ................................................................................................................................ 1-1
2 Preparation ............................................................................................................................................. 2-1
2.1 Preparation................................................................................................................................. 2-1
3 Learning units ......................................................................................................................................... 3-1
3.1 1. Step: Mount mounting rails and modules .............................................................................. 3-1
3.2 2. Step: Wiring the power supply and CPU ............................................................................... 3-3
3.3 3. Step: Commissioning the hardware....................................................................................... 3-4
3.4 4. Step: Set up the PG/PC interface .......................................................................................... 3-5
3.5 5. Step: Configuring hardware in HW-Configuration of STEP 7 ................................................ 3-6
3.6 6. Step: To insert CPU 317-2 PN/DP and assign it and IP address .......................................... 3-7
3.7 7. Step: Commissioning the CPU 317-2 PN/DP ...................................................................... 3-10
4 Further Information ................................................................................................................................. 4-1

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 iii
Table of contents

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
iv Getting Started, 12/2006, A5E00268410-03
Introduction 1
1.1 Introduction

Introduction
In the following steps we will show you the basics of configuring the PROFINET interface.
To do so we will be using the CPU 317-2 PN/DP as an example.
The procedure for configuring the PROFINET interface of the CPU 315-2 PN/DP and
319-3 PN/DP is the same as that used to configure the CPU 317-2 PN/DP.
Depending on your previous experience this configuration will take between one and two
hours to complete.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 1-1
Introduction
1.1 Introduction

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
1-2 Getting Started, 12/2006, A5E00268410-03
Preparation 2
2.1 Preparation

Scope

CPU Order number SIMATIC Micro Memory Card As of version


required for operation?
Firmware
315-2 PN/DP 6ES7315-2EH13-0AB0 Yes V2.3.4
317-2 PN/DP 6ES7317-2EK13-0AB0 Yes V2.3.4
319-3 PN/DP 6ES7318-3EL00-0AB0 Yes V2.4.0

Requirements
• Basic knowledge of electronic and electrical systems engineering.
• Knowledge in the area of network engineering would be of advantage.
• You have already worked with the STEP7 programming software.
• We assume that you are familiar with the Microsoft® Windows™ operating system.

Warning
Operation of an S7-300 as part of plants or systems is subject to special rules and
regulations, based on its field of application. This includes current safety regulations and
directives for the prevention of accidents, such as IEC 204 (EMERGENCY-OFF
equipment.)
You risk severe injury, or damage to machines and equipment if you ignore these
directives.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 2-1
Preparation
2.1 Preparation

Material and tools required

Quantity Article Order number (Siemens)


1 Mounting rail such as 6ES7 390-1AE80-0AA0
1 Power supply (PS) module such as 6ES7 307-1EA00-0AA0
1 CPU 315-2 PN/DP 6ES7315-2EH13-0AB0
or
CPU 317-2 PN/DP 6ES7317-2EK13-0AB0
or
CPU 319-3 PN/DP 6ES7318-3EL00-0AB0
1 SIMATIC Micro Memory Card for example, 6ES7 953-8LL11-0AA0
Note:
The SIMATIC Micro Memory Card is essential for the operation of the
CPU.
1 • Programming device (PG) or PC with Ethernet network card, depending on the configuration
100 Mbps, full duplex
• installed software STEP 7 V5.3 + SP1 or higher
1 Switch, SCALANCE X208, for example 6GK5 208-0BA00-2AA3
1 Industrial Ethernet Twisted Pair cable (Cat5) with RJ45 connectors for example, 6XV1 850-2GH60
(Patch cable TP Cord RJ45/RJ45, length = 6 m)
various M6 screws and nuts (lengths depend on place of installation) and commonly available
matching wrench / screwdriver
1 Screwdriver with 3.5 mm blade commonly available
1 Screwdriver with 4.5 mm blade commonly available
1 Side cutters and wire stripping tools commonly available
1 Crimp tool for wire ferrules commonly available
0.5 m 1-wire flexible cable, conductor cross-section 1 mm2, with wire end commonly available
ferrules, for connecting the power supply and CPU
Xm Cable for grounding the mounting rail with 10 mm2 cross-section and commonly available
cable lug to fit M6, length appropriate for local requirements.
Xm 3-wire flexible network cable (AC 230/120 V) with grounding-type socket commonly available
outlet; length appropriate for local requirements with suitable wire end
ferrules with shrouded contacts.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
2-2 Getting Started, 12/2006, A5E00268410-03
Preparation
2.1 Preparation

Configuring the PROFINET interface

 
 

 

&38
36 31'3






Figure 2-1 Configuring with CPU 317-2 PN/DP

(1) Bus error display


(2) Status and error displays
(3) Bay for SIMATIC Micro Memory Card
(4) Mode selector switch
(5) Industrial Ethernet Twisted Pair cable for interconnecting PN interface X2
(6) Industrial Ethernet Twisted Pair cable for connecting to PROFINET IO (ET 200S, for
example)
(7) Industrial Ethernet Twisted Pair cable for interconnecting the PG with the SCALANCE X208
switch
(8) Programming device (PG) with STEP7 software
(9) Mounting rail
(10) Power supply ON/OFF
(11) Setting of supply voltage

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 2-3
Preparation
2.1 Preparation

1 2

L+
4
M

L+ 5
M
L+

DC 24V
M L+
M

8 7 6

220V/ 120V

Figure 2-2 Wire the power supply and the CPU (front panel covers are open.)

(1) Power supply (PS) module


(2) CPU 317-2 PN/DP
(3) Status indication of the second interface X2
(4) MPI interface X1 to Connection to the PG
(5) PROFINET interface to the terminals to Industrial Ethernet
(6) Removable power supply connection
(7) Connecting cables between PS and CPU
(8) Strain relief

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
2-4 Getting Started, 12/2006, A5E00268410-03
Learning units 3
3.1 1. Step: Mount mounting rails and modules

Install and ground the mounting rail


1. Screw on the mounting rail (screw size: M6). Make sure to maintain a minimum clearance
of 40 mm above and below the mounting rail.
When mounting it on a grounded metallic panel or on a grounded device mounting panel
made of steel sheet, make sure you have a low impedance connection between the
mounting rail and the mounting surface.
2. Connect the rail to the protective conductor. An M6 protective conductor screw is
provided on the mounting rail for this purpose.
Stipulated cross-section of the cable connection to the protective conductor: at least
10 mm2.

1.

2.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 3-1
Learning units
3.1 1. Step: Mount mounting rails and modules

Installing modules on the mounting rail


1. First of all, insert the power supply module. Slide it to the left until it meets the grounding
screw of the mounting rail and then screw it on.
2. To connect further modules, insert a bus connector into the CPU (see drawing section).

3. Hang in the CPU (1).


4. Slide it up to the left module (2).
5. You can then swing it down (3).

2 1

6. Screw-tighten the modules on the mounting rail.


7. Insert the SIMATIC Micro Memory Card into its slot on the CPU: The SIMATIC Micro
Memory Card is essential for operation.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
3-2 Getting Started, 12/2006, A5E00268410-03
Learning units
3.2 2. Step: Wiring the power supply and CPU

Note
To use a SIMATIC Micro Memory Card with unknown content, erase it on the PG before
doing so.

3.2 2. Step: Wiring the power supply and CPU

Warning
You may come into contact with live wires that are connected to the power supply. Make
sure that the S7-300 is completely disconnected before you start wiring.

Procedure
1. Open the front panels of the power supply and the CPU.
2. Detach the strain relief clip from the power supply.
3. Strip the flexible power cable, dress it with crimped wire ferrules and connect the IE/PB-
Link to the power supply module (blue on terminal M, black on terminal L1, protective
conductor on terminal PE).
4. Screw the strain relief clamp in place.
5. Next, wire the power supply to the CPU. Use flexible cable with a conductor cross-section
of 1 mm2.
Strip the ends to a length of approx. 6 mm, the crimp on the wire end ferrules. Connect
terminals L+ and M on the power supply to those on the CPU.
6. Check that the line voltage selector switch is set to the correct line voltage.
The default line voltage setting for the power supply module is 230 VAC.
To label a front connector, follow the steps outlined below:
– Remove the protective cap with a screwdriver,
– set the selector switch to match your line voltage,
– then insert the protective cap again.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 3-3
Learning units
3.3 3 . Step: Commissioning the hardware

3.3 3. Step: Commissioning the hardware

Procedure
1. Connect the PG/PC to the switch. Use the twisted-pair cables with RJ45 connectors.
Result: The PG/PC is interconnected with the CPU.
2. Connect the switch to PROFINET interface X2 of your CPU with Industrial Ethernet. Use
the twisted-pair cables with RJ45 connectors.
Result: The CPU is connected to the switch.
3. Connect the PROFINET IO device (ET 200S for example) to the switch. Use the twisted-
pair cables with RJ45 connectors.
Result: The IO device is connected to the switch.
4. Verify that the SIMATIC Micro Memory Card is inserted in the CPU slot.
5. Close the front panel cover of the CPU, then set the mode selector switch on the CPU to
STOP.
6. Connect the mains cable, then switch on the power supply module.
Result: The DC24V-LED of the power supply module is lit.
All the LEDs of the CPU light briefly; the SF-LED and the DC5V-LED stay lit. The STOP-
LED then flashes rapidly when the CPU performs an automatic memory reset.
After completion, the STOP LED is lit.
7. Start your PG/PC, then run SIMATIC Manager from your Windows Desktop.
Result: A window opens with SIMATIC Manager.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
3-4 Getting Started, 12/2006, A5E00268410-03
Learning units
3.4 4 . Step: Set up the PG/PC interface

3.4 4. Step: Set up the PG/PC interface

Procedure
1. Select "Start > SIMATIC > STEP 7 > Customize PG/PC interface".
Result: The dialog box for setting the PG/PC opens.

2. Select the access path. Then set the TCP/IP protocol for the network card used.
Click "Properties". Set the "Assign project-specific IP address" option in the "Properties"
dialog box. Confirm twice with "OK".
Result: Your PG/PC settings are applied.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 3-5
Learning units
3.5 5 . Step: Configuring hardware in HW-Configuration of STEP 7

3.5 5. Step: Configuring hardware in HW-Configuration of STEP 7

Create a new project in STEP 7


1. Select "File > New..."
2. Enter a name for your project and click on OK to confirm.
Result: A new project is created

Add a new S7-300 station


1. Select "Insert > Station > SIMATIC 300 Station".
Result: The SIMATIC 300 (1) icon in the right-hand part of the window is highlighted.

Add a rail
1. In the right-hand part of the window, double-click first on the SIMATIC 300(1) icon and
then on the Hardware icon.
Result: The hardware configuration editor (HW Config) opens.
2. You can insert your hardware components from the hardware catalog in the left-hand part
of the window.
If no catalog is displayed, use the menu command View > Catalog to activate this.
In the hardware catalog, select SIMATIC 300 and then Rack 300. Drag-and-drop the
mounting rail to the upper part of the HW Config window.
Result: This pastes the mounting rail into the upper section of the HW Config window.

Add the power supply:


1. In the hardware catalog, navigate to PS-300. Drag your power supply and drop it into slot
1 on the rail.
Result: The power supply module is inserted into slot 1.

Note
You can click the power supply module to view its order number. The order number then
appears in the box beneath the catalog.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
3-6 Getting Started, 12/2006, A5E00268410-03
Learning units
3.6 6. Step: To insert CPU 317-2 PN/DP and assign it and IP address

3.6 6. Step: To insert CPU 317-2 PN/DP and assign it and IP address

Introduction
Each Ethernet node is identified by a international unique address. This so-called MAC
address is preset by the manufacturer and cannot be changed.
In the following steps you will assign an IP address in the the Ethernet to this physical
address.

Procedure
1. Select CPU-300 from the hardware catalog. Drag-and- drop the CPU 317 PN/DP to slot 2
of the mounting rail.
The CPU 317-2 PN/DP is inserted in slot 2 and the properties dialog box of the
PROFINET interface X2 is displayed.

2. Enter the IP address and the subnet mask.


When working on a corporate network, contact your network administrator for information
about this address.
3. If you setup a connection via router, you must also enter the address of the router.
When working on a corporate network, contact your network administrator for information
about this address.
4. Click "New", then assign a name for a new Industrial Ethernet subnet. Confirm your
entries with "OK".
Result: You created a new Industrial Ethernet subnet.
5. Click on the "OK" button.
Result: The properties window of PROFINET interface X2 for CPU 317-2 PN/DP closes.
6. In HW-Config you can now also set the options of the PROFINET interface:
In HW-Config, double click the PROFINET interface X for the CPU 317-2 PB/DP.
If necessary, change to the "Options" tab. There you can customize the network settings.
Default is "Automatic Settings", which is usually sufficient for error-free communication.
Communication problems (connections fail, or frequent network errors, for example) may
be caused by faulty settings, or by the automatic network settings.
In this case, adjust your network settings to match you network configuration.
Result: You can customize the network settings in HW-Config.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 3-7
Learning units
3.6 6. Step: To insert CPU 317-2 PN/DP and assign it and IP address

Save and compile your configuration:


1. Select the menu command "Station > Save and compile".
Result: The hardware configuration is compiled and saved.
2. Select the menu command "PLC > Download to module".
Result: The dialog box for the selection of the target group is displayed.

CPU 317-2 PN/DP is already selected as target module.


3. Confirm the dialog with "OK".
Result: The dialog box for the selection of the station address is displayed.

The CPU is not yet displayed in "stations reached".

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
3-8 Getting Started, 12/2006, A5E00268410-03
Learning units
3.6 6. Step: To insert CPU 317-2 PN/DP and assign it and IP address

4. Click "View".
Result: The PG reads the MAC address and shows it on the dialog box.

5. Select the line with the MAC address of the CPU and confirm with "OK".
Result: The message window opens.

6. Confirm the message with "Yes".


Result: IP address is assigned to the CPU and the configuration is loaded.

7. Close HW-Config via the menu command "Station > Close" and answer question
regarding saving with "Yes".
Result: HW Config is closed. The CPU now appears in the station in SIMATIC Manager.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 3-9
Learning units
3.7 7. Step: Commissioning the CPU 317-2 PN/DP

3.7 7. Step: Commissioning the CPU 317-2 PN/DP

Procedure
1. Set the mode switch of the CPU to "RUN".
Result: The STOP LED is off. The RUN LED starts to flash and then assumes a
continuous signal.
The LINK LED indicates a physical Ethernet connection.
The RX/TX LED is lit or flashes when data are transmitted/received via Ethernet.

Result
You completed the STEP 7 configuration of PROFINET interface X2 of your CPU 317-2
PN/DP.
• Other nodes can now access the CPU on the Ethernet subnet.
• The new functions now allow you to configure your project, or to reconfigure it, via the
integrated PROFINET interface of the CPU.
• All PG/OP functions and other communication functions of CPU 317-2 PN/DP are now
available via integrated PROFINET interface.

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
3-10 Getting Started, 12/2006, A5E00268410-03
Further Information 4
Reference
For detailed information on address assignment for the PROFINET interface, refer to the
STEP 7 Online Help.

Diagnostics/Correction of Errors
Wrong operation, faulty wiring or a faulty hardware configuration may cause errors which the
CPU indicates with the SF group error LED after a CPU memory reset.
For information on how to analyze such errors and alarms, refer to the CPU 31xC and CPU
31x operating instructions, Setup.

Manuals containing further information


• Getting Started: Getting started and exercises with STEP 7
• Manual: SIMATIC NET: Twisted Pair and Fiber Optic Networks
• Manual: SIMATIC communication

Service & Support on the Internet


In addition to our documentation, we offer a comprehensive online knowledge base on the
Internet at:
http://www.siemens.com/automation/service&support
There you can find:
• A newsletter containing the latest information on your Siemens products.
• The documents you need using our search engine in Service & Support.
• the bulletin board, a worldwide knowledge exchange for users and experts.
• your local contact for Automation & Drives in our contact database.
• Information about on-site services, repairs, spare parts. You will find much more under
"Services".

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
Getting Started, 12/2006, A5E00268410-03 4-1
Further Information

CPU 315-2 PN/DP, 317-2 PN/DP, 319-3 PN/DP: Configuring the PROFINET interface
4-2 Getting Started, 12/2006, A5E00268410-03

Вам также может понравиться