beautypg.com

Tasks, H task – Delta RMC151 User Manual

Page 304

background image

RMC70/150 and RMCTools User Manual

processed a non-immediate command this control loop. Command sets

remaining in the command queue will be processed in subsequent control loops.

Notice that commands issued as part of the same command set will never be

split between different control loops. That is, either all of the commands in the

command set will be processed in the control loop, or none of them will be and

the entire command set will be deferred to the next control loop.
The command queue has a finite length. The RMC70 command queue allows up

to 6 command sets, each set with up to one command per axis. The RMC150

allows up to 12 command sets. If the command queue is full when a new

command set is received, the command set will be discarded, and Runtime Error

201 (Command block dropped) will be logged in the Event Log. This condition

can only practically occur in cases where non-immediate commands are being

issued continuously from a user program. Notice that Expression commands are

immediate commands and are therefore safe to issue continuously from user

programs.

5.3. Tasks

Tasks are for running User Programs. Each task is an execution engine that can run one User

Program at a time.
The RMC70 has up to four tasks. Therefore, the RMC70 can run up to four User Programs

simultaneously. The RMC150 has up to ten tasks. Therefore, the RMC150 can run up to ten

User Programs simultaneously. Use the Task Monitor to monitor what each task is doing. To

change the number of tasks, see the Changing the Number of Tasks below.
To start running a User Program on a task, use the Start Task (90) command.

Example
You have created a User Program called MyProgram. You want to run MyProgram. To do

this, you need to run it on a task. Use the Start Task (90) command to start running

MyProgram on any task, for example task 0.
Example
You have created two User Programs called MyProgram1 and MyProgram2. You want to

run MyProgram1 and MyProgram2 simultaneously. To do this:

1. Use the Start Task (90) command to start running MyProgram1 on any task, for

example task 0.

2. Since task 0 is already running, you must start MyProgram2 on another task, for

example on task 1. If you were to start MyProgram2 on task 0, then task 0 would

immediately stop running MyProgram1, and then start running MyProgram2. Then

they would not be running simultaneously.

Note:

In order to run tasks or the Program Triggers, the RMC must be in RUN mode. See the

RUN/PROGRAM Mode topic for details.

Starting Tasks

Tasks can be started in several ways:

Start Task (90) command

Send a command to specify which user program to run on a certain task.

Program Trigger

Automatically start a task based on a user-defined condition. See the Program

Triggers topic for details.

284

Delta Computer Systems, Inc.

This manual is related to the following products: