Learning Targets ..............................................................................................................................
2
Creating and importing block libraries ............................................................................................... 3
Exercise 1: Generate a function block library .................................................................................... 9
Exercise 2: Generate a project independent DCB library .................................................................. 14
SITRAIN Page Course DR-S12-PA
Training Document 8-1 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I TR
A S
D I
I N
A I N
I T R
S
D I A
I N
A I N
IT R
A S
D I
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-2 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I TR
A S
D I
I N
A I N
I T R
S Notes
D I A
I N
A I N
IT R
A S
D I
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-3 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I TR
A S
D I
I N
A I N
I T R
S Notes
D I A
I N
A I N
IT R
A S
D I
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-4 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Import block
libraries Block libraries can be imported at any time in DCC/CFC:
>> Options > Block types ...> Import > Import library ...
D I A
I N
A I N
IT R
A S
D I
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-5 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I TR
A S
D I
I N
A I N
I T R
S Notes
D I A
I N
A I N
IT R
A S
D I
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-6 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I TR
A S
D I
I N
A I N
I T R
S Notes
D I A
I N
A I N
IT R
A S
D I
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-7 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Requirements Status of the device:
• First commissioning completed
Safety information Please note that:
• The exercise instructions are intended for:
D I A
- a course held by an instructor
I N
- actions on special training devices
A I N
• The training equipment is operated under laboratory conditions.
IT
electrical current or moving parts. R
In case of doubt, always ask your instructor, particularly when handling
S
• The safety instructions in the relevant product documentation must be
followed at all times when working on the devices!
A
I
The training documents alone are not sufficient.
D
N IN
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8-8 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Task Create a custom block library with 2 blocks within your open project.
Proceed as follows to do this:
1. For a comparison between online and offline data, first perform
>> Upload to PG and then switch to the offline view of your project.
D I A
2. In your project, open the directory
"LIBRARIES SINAMICS" and there activate I N
>> Insert DCC library
3. Name this library "Bib_Drehzahlregelung"
A I N
>> Insert DCC charts
IT R
4. Now open the newly created library and there activate
S
5. Name this chart "Control logic"
A
D I
6. Insert two AND blocks and one OR block in this chart as shown in the figure
above.
Note on the library
N IN
The name for a block library can a max. of 25 characters in length!! Avoid using
A I special characters except the "underscore".
I T R
Note on the chart The name for a chart can a max. of 22 characters in length!! Avoid using special
characters except the "underscore".
SITRAIN Page Course DR-S12-PA
Training Document 8-9 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Task Use the Interface Editor to define the input and output parameters for this block,
so that you can interconnect this block when calling it in an object-specific chart.
Procedure
1. Open the CFC interface editor.
D I A
I N
2. Open the input interface "IN" in the editor and drag the input signals into the
interface as shown in the picture above.
A I N
IT
OR block into the output interface. R
3. Now open the output interface "OUT" and drag the output parameters of the
A S
4. Compile your chart and make sure that no errors are reported during
I
compilation:
D
N IN
5. First close your CFC and switch to "STARTER".
A I
T R
SI
SITRAIN Page Course DR-S12-PA
Training Document 8 - 10 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Task Import your custom "Control logic" block and call it on under your "SERVO_02"
drive object.
Procedure
1. Open your existing DCC under "SERVO_02".
D I A
I N
2. Select "Bib_Drehzahlregelung" in your CFC block library with
>> Options > Block types … > OK
I N
3. Import your library in the chart of your drive object using the ">>" button and
start the import with the "Apply" button
A
in your subchart "A".
IT R
4. Open the "Bib_Drehzahlregelung" library and drag the "Control logic" block
S
5. Publish the input and output parameters at the block and interconnect them
A
I
in accordance with the following rules:
D
IN
I1 çè CU320-2.DI0
I2 çè CU320-2.DI1
A I N I3 çè CU320-2.DI2
Q çè Servo_02.p840
I T R 6. Compile your chart and make sure that no errors are reported during
compilation:
S 7. First close your CFC and switch to "STARTER".
8. Make an online connection to your drive, download the offline data to the
target system and check the function of the control logic in online mode
SITRAIN Page Course DR-S12-PA
Training Document 8 - 11 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Task The existing block library must be revised and functionality added to it. To do
this, you will require a 4th digital input for the control logic.
Procedure
1. For a comparison between online and offline data, first perform
D I A
2. In your project, open the "Bib_Drehzahlregelung" library I N
>> Upload to PG and then switch to the offline view of your project.
I N
in the directory "LIBRARIES SINAMICS" and the "Control logic" chart there
A
3. In this chart, add a 2nd input at the 2nd AND block in the input interface of
this block.
IT R
4. Compile your chart and make sure that no errors are reported during
compilation:
A S
D I
5. Import your updated library in the chart of your drive object using the ">>"
button and start the update with the "Apply" button
N IN
6. Publish the additional input parameters at the block and interconnect it in
accordance with the following rules:
A I I4 çè CU320-2.DI3
T R 7. Compile your chart and make sure that no errors are reported during
SI
compilation:
8. First close your CFC and switch to "STARTER".
9. Make an online connection to your drive, download the offline data to the
target system and check the function of the control logic in online mode
SITRAIN Page Course DR-S12-PA
Training Document 8 - 12 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Task The existing block library must supplemented with a function for adapting the
speed setpoint.
Procedure
1. For a comparison between online and offline data, first perform
D I A
2. In your project, open the "Bib_Drehzahlregelung" library I N
>> Upload to PG and then switch to the offline view of your project.
I N
in the directory "LIBRARIES SINAMICS" and the "Setpoint adjustment" chart
there
A
IT
Pay attention to the interfaces! R
3. In this chart, add the "MUL" block , which makes your analog input scalable.
compilation:
A S
4. Compile your chart and make sure that no errors are reported during
D I
5. Import your updated library in the chart of your drive object using the ">>"
IN
button and start the update with the "Apply" button
6. Add the "Setpoint adjustment" block to your object-specific chart and publish
A I N Input 1 and the output as an interconnection parameters and Input 2 as
value parameters.
T R 7. Make the following interconnection at the "Setpoint adjustment" block:
SI
X1 çè TB30.AI0
Y çè SERVO_02.p1155
8. Compile your chart without errors.
9. Make an online connection to your drive, download the offline data to the
target system and check the function of the control logic in online mode by
decreasing the value in the expert list to your scale parameter.
SITRAIN Page Course DR-S12-PA
Training Document 8 - 13 Drive Control Chart - Function Block Libraries
D I A
I N
A I N
I T R
A S
D I
I N
A I N
I T R
S Task The existing block library should be configured independent of the project and
stored as a DCB library.
Procedure
1. In your project, copy the two DCCs in the directory "LIBRARIES SINAMICS"
D I A
to the clipboard .
2. Close your existing project. I N
3. Use STARTER to create a new project:
>> Project > New > "S120_Library_1".
A I N
IT R
4. In this project, open the directory "BIBLIOTHEKEN SINAMICS"
and insert the two DCCs from the clipboard.
S
5. Open one of the two charts.
A
D I
6. Compile the two charts and make sure that no errors are reported during
compilation:
N IN
7. Create the DCB library as follows:
>> Select library > Right-click > Create DCB library
A I 8. Close your existing project.
T R 9. Create an empty project and execute the following instruction in it:
>> Options > Install block libraries …
SI 10. Now open your target project again and import it your previously installed
library using the ">>" button.
11. Use these blocks in your DCC and then compile your chart without errors.
SITRAIN Page Course DR-S12-PA
Training Document 8 - 14 Drive Control Chart - Function Block Libraries