Omron NJ-series User Manual page 135

Machine automation controller cpu unit software
Hide thumbs Also See for NJ-series:
Table of Contents

Advertisement

5 Designing Tasks
Additional Information
An event task is not executed periodically. Instead, it is executed only once when the specified
execution condition is met. Therefore, execution of an event task depends on when its execution
condition is met and on its execution priority.
Examples of Execution Order for Tasks
This section gives a few examples of the execution order for the primary periodic task and periodic
tasks. Refer to 5-2-5 Event Task Execution Timing for the order of execution of event tasks.
 Projects with Only the Primary Periodic Task
The primary periodic task is executed every primary period. The system service shown in this figure
refers to non-task related processing, such as communications processing, that is performed by the
CPU Unit. System services are executed in the unused time between execution of the tasks. Refer
to Processing Performed in System Services on page 5-29 for details on the system services.
Execution priority
High
Primary
periodic
task
System
services
Low
 Project with the Primary Periodic Task, Priority-16 Periodic Task, and Priority-
17 Periodic Task
• The primary periodic task has the highest execution priority, so it is always executed in the primary
period.
• The priority-16 periodic task has a lower execution priority than the primary periodic task, so it is
executed when the primary periodic task is not being executed.
• The priority-17 periodic task has an even lower execution priority, so it is executed when the above
two tasks are not under execution.
• In this example, the task period for the priority-16 periodic task is set to four times the primary
period. This means that once ever four primary periods, execution of the primary periodic task and
the priority-16 periodic task will start at the same time.
• System services are executed in the unused time between execution of the tasks.
5-8
Primary period
IO
UPG
MC
SS
A dotted line represents a transition to another task.
IO: Indicates I/O refreshing (data outputs and then data inputs).
UPG: User program execution.
MC: Indicates motion control.
SS: Indicates system services.
Primary period
IO
UPG
MC
SS
Pausing
NJ-series CPU Unit Software User's Manual (W501)
A double line means
that all processing for
that task has been
completed.

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents