Periodic tasks coming up with warnings

Mgw1970

Member
Join Date
Jul 2019
Location
Magna
Posts
33
The original file uses a STI and I/O interrupts {micrologix1500}, but when I create them as a periodic tasks in studio5000 I get warnings routine doesn't have an association with main program. Is this normal or did miss something setting up the task? Thanks!
 
Did you schedule any program(s) within the task properties? Have you assigned a main routine in the program properties? Are all non-main routines called by the main routine (directly or indirectly)?
 
You'll need to familiarize yourself with Tasks, Programs and Routines. In simple terms:

  • A Routine is similar to LAD routines in the MicroLogix. However, instead of LAD2 that executes automatically, you must define a "main" routine. This will be the routine that executes automatically whenever that task executes. Other routines would be subroutines or a fault routine. Logic is always contained in Routines. Tasks and Programs do not contain logic themselves.
  • A Program is a grouping of related routines within a Task. Sort of like a folder. A Task may have multiple Programs. Each Program has its own Main routine and subroutines. You can have up to 65,000 routines in each Program.
  • A Periodic Task is essentially a container where you define how often it will execute its Programs and in what order the programs will run. The number of Programs depends a little on the firmware of the controller. I believe you can have 1000 Programs per Task. I think that used to be 32 when the Logix 5000 was first introduced. Some CompactLogix are limited to 16.

    The number of Tasks will vary based on your controller. But I believe 32 is the maximum. Only one task may be defined as the continuous task.

Obviously, that is a very simple explanation. But that should get you started at least.
 
Last edited:
You'll need to familiarize yourself with Tasks, Programs and Routines. In simple terms:

  • A Routine is similar to LAD routines in the MicroLogix. However, instead of LAD2 that executes automatically, you must define a "main" routine. This will be the routine that executes automatically whenever that task executes. Other routines would be subroutines or a fault routine. Logic is always contained in Routines. Tasks and Programs do not contain logic themselves.
  • A Program is a grouping of related routines within a Task. Sort of like a folder. A Task may have multiple Programs. Each Program has its own Main routine and subroutines. You can have up to 65,000 routines in each Program.
  • A Periodic Task is essentially a container where you define how often it will execute its Programs and in what order the programs will run. The number of Programs depends a little on the firmware of the controller. I believe you can have 1000 Programs per Task. I think that used to be 32 when the Logix 5000 was first introduced. Some CompactLogix are limited to 16.

    The number of Tasks will vary based on your controller. But I believe 32 is the maximum. Only one task may be defined as the continuous task.

Obviously, that is a very simple explanation. But that should get you started at least.

Thanks! I went back through and got the tasks/routines situated correctly.
 

Similar Topics

Curios on the thoughts of using Continuous vs Periodic tasks. . The old SLC-500's mostly only had Continuous tasks. . The Compact & Control...
Replies
49
Views
13,800
Hi everyone, Suppose I have a periodic task to trigger some communications, and in this task I have a pointer that iterates for each...
Replies
3
Views
1,307
Hello, Monitoring my system with the Studio5000 Task Monitor I see a yellow banner "Continuous Task is present, resulting in 100% CPU...
Replies
78
Views
34,958
Hello. I'm trying to figure out if it is better to have multiple PID loops in 1 periodic task, or have several (5) periodic tasks? I'm thinking 5...
Replies
4
Views
3,613
Hi all, If I have 2 periodic tasks (with the same priority number) configured to execute at the same period (say, 10ms), which one is going to be...
Replies
0
Views
2,085
Back
Top Bottom