EasyManuals Logo

Siemens Simatic S7-1500R Function Manual

Siemens Simatic S7-1500R
79 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #14 background imageLoading...
Page #14 background image
Cycle and response times
Function Manual, 10/2018, A5E03461504-AD
13
Program execution
2
2.1
Principle of operation
Introduction
You often program your user program with a cyclic OB, usually in OB 1. With complex
applications, problems are often encountered in complying with the response times required
by the application. You can often meet the response time requirements by splitting the user
program up into several parts with different response time requirements. The CPU offers a
number of different OB types for this purpose, the properties (priority, frequency, etc.) of
which can be adapted to meet your requirements.
Program organization
You can choose from the following types of program execution for running your user
program:
Program execution in the cyclic program of the CPU:
The CPU executes the user program cyclically. When the execution has reached the end of
a cycle, the program execution starts again in the next cycle. In the simplest case, you
execute the entire user program in the cyclic program of the CPU. All tasks in the user
program are then processed with equal rank. This also results in the same response times
for all tasks.
In addition to program execution in the cyclic program, there is time-driven and event-driven
program execution.
Time-driven execution:
In a complex user program, there are frequently portions with different response time
requirements. You can optimize the response times by taking advantage of these differences
in the requirements. To do so, you can break down the program parts with higher response
time requirements into higher-priority OBs with shorter cycles, for example cyclic interrupt
OBs.
The execution of these parts can thus occur at different frequencies and with different
priorities.
Event-driven execution:
Depending on the I/O modules used, you can configure hardware interrupts for specific
process events (such as an edge change of a digital input) that result in the call of the
assigned hardware interrupt OB. The hardware interrupts have a higher priority and interrupt
the cyclic program of the CPU. You can achieve very short response times in the CPU with
hardware interrupts by directly triggering program execution.
Keep in mind that the time characteristics of your application becomes less predictable with
intense use of hardware interrupts. The reason for this is that the time at which the triggering
events occur can result in drastically different response times.
Tip:
Use hardware interrupts only for a few selected events.
Special consideration for hardware interrupts:
If you have assigned an OB to an event
(hardware interrupt), the OB then has the priority of the event.

Other manuals for Siemens Simatic S7-1500R

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens Simatic S7-1500R and is the answer not in the manual?

Siemens Simatic S7-1500R Specifications

General IconGeneral
BrandSiemens
ModelSimatic S7-1500R
CategoryController
LanguageEnglish

Related product manuals