Inserting Program Code For Calling The Basic Program - Siemens SINUMERIK MC Commissioning Manual

Mcu commissioning: nc, plc, drive
Hide thumbs Also See for SINUMERIK MC:
Table of Contents

Advertisement

PLC commissioning
5.4 Creating a PLC program
Instead, add these organization blocks yourself and insert call and initialization of the basic
program at the beginning of each OB.
Table 5-1
Organization blocks of the basic SINUMERIK PLC program
Name
Address
(default set‐
(default
ting)
setting)
Startup
OB100
Main
OB1
Hardware in‐
OB40
terrupt
5.4.4

Inserting program code for calling the basic program

Because the organization blocks of the PLC program must contain both calls of the
SINUMERIK PLC basic program and calls of your PLC user program, these organization
blocks are not available as copy templates in the system library.
Instead, add these organization blocks yourself and then insert the program code for calling
and initializing the PLC basic program.
For example, you can type these calls directly in the editor, copy them from a program example
(SCL) and paste them into the editor or create them with drag and drop.
Requirement
● The respective organization block is added.
Note
Selecting the programming language for Main [OB1]
A newly added MCU already contains Main [OB1] in the LAD programming language. You
can change the programming language to FBD in the block properties or delete the existing
block and add it back again as an STL block or SCL block.
● The basic SINUMERIK PLC program blocks that are to be called from the respective
organization block are added in the "Program blocks" folder of the project tree.
68
Description
Startup OBs are processed once when the mode of the CPU
switches from STOP to RUN. After execution of the startup OB,
execution of the cycle OB starts.
Cycle OBs are higher-level logic blocks in the program that are
cyclically processed and in which you can program instructions
or call additional blocks.
Hardware interrupt OBs interrupt the cyclic program processing
due to a hardware event. You define the event in the hardware
properties.
PLC basic program block to
be called
LBP_ConfigBP [FC1]
LBP_MainBP [FC2]
LBP_NCKProcessIRT [FC3]
MCU commissioning: NC, PLC, Drive
Commissioning Manual, 02/2020, A5E47437618B AB

Advertisement

Table of Contents
loading

Table of Contents