7.11 Cooperative Multitasking
As of NC software:
280 472-01
7.11.1 STARTING A PARALLEL PROCESS (SPAWN)
December 2001
You can run several processes in the PLC with cooperative multitasking.
Unlike genuine multitasking, with cooperative multitasking information and
tasks are exchanged only at places that you define. Cooperative multitasking
permits up to eight parallel PLC processes and the submit queue. In a program
that you have started with SUBM, you can use commands for changing tasks
and controlling events (Module 926x). You should additionally insert a task
change between the individual jobs in the submit queue, so that the TNC can
execute parallel processes by the end of a job at the latest. The cyclic PLC
main program does not participate in cooperative multitasking, but interrupts
a submit job and the parallel processes at whatever stage they are at.
Syntax:
SPAWN <label>
Operands:
D
Action:
In the specified double word, the TNC returns the identifier, See "Submit
Programs" on page 7 – 159. If no process could be started, the TNC returns
the value –1. You can call the spawn only in a submit job or in another spawn
process (maximum of eight parallel processes are permitted). If a process
ends with EM, the TNC removes it from the memory to provide space.
Cooperative Multitasking
7 – 163